🤑 Join the Treehouse affiliate program and earn 25% recurring commission!

New No-Code Track! 🚀start learning today!

🌟 Dreaming of a bright future? 🎓 Ask about the Treehouse Scholarship program! 🚀

✨ Earn college credits in Cybersecurity, JS, HTML, CSS and Python

  • Treehouse Logo
  • Plans
    Chevron
    • For Individuals
    • For Businesses
    • For Schools
    • For Libraries
    • For Military
  • Library
    Chevron
    • All Courses
    • Tracks
    • College Credit
  • Techdegree
    Chevron
    • Overview
    • Front End Development
    • Full Stack JavaScript
    • Data Analysis
    • UX Design
    • Python
  • Community
    Chevron
    • Code Adventures
    • Discord
    • Forum
    • Success Stories
    • Treehouse Links
    • 100 Days of Code
  • Resources
    Chevron
    • Career Toolbox
    • CodeForward
    • Free Treehouse Near Me
    • Jobs
    • Blog
    • Support
    • About
  • For Individuals For Businesses For Schools For Libraries For Military
  • All Courses Tracks College Credit
  • Overview Front End Web Development Full Stack JavaScript Python Development Data Analysis UX Design
  • Code Adventures Discord Forum Success Stories Treehouse Links 100 Days of Code
  • Career Toolbox CodeForward Free Treehouse Near Me Jobs Blog Support About
  • Sign In
  • Free Trial
Instagram Twitter Facebook YouTube LinkedIn
    • Newest
      • Newest
      • Active
      • Unanswered
      • Featured
    • All Topics
      • All Topics
      • • General Discussion
      • • AI
      • • Android
      • • APIs
      • • Coding for Kids
      • • College Credit
      • • Computer Science
      • • CSS
      • • Data Analysis
      • • Databases
      • • Design
      • • Development Tools
      • • Digital Literacy
      • • Game Development
      • • Go Language
      • • HTML
      • • Java
      • • JavaScript
      • • Learning Resources
      • • Machine Learning
      • • No-Code
      • • PHP
      • • Professional Growth
      • • Python
      • • Quality Assurance
      • • React
      • • Ruby
      • • Security
      • • Swift
  • Janina Alvarez
    Janina Alvarez
    8,083 Points

    Why does an arrow function not allow "this" access, but function() {} does?

    Posted June 13, 2024 4:48am by Janina Alvarez
    Janina Alvarez
    8,083 Points
    • JavaScript
    • Practice Object Basics in JavaScript
    • Practicing Object Basics
    • Practice Adding a Method to an Object Literal

    1 Answer

  • Fendy Azman
    Fendy Azman
    8,514 Points

    Problem with returning number of char in string

    Posted July 31, 2023 2:40am by Fendy Azman
    Fendy Azman
    8,514 Points
    • JavaScript
    • Practice Object Basics in JavaScript
    • Practicing Object Basics
    • Practice Adding a Method to an Object Literal

    1 Answer

  • Samuel Kleos
    seal-mask
    .a{fill-rule:evenodd;}techdegree
    Samuel Kleos
    Front End Web Development Techdegree Student 13,728 Points

    I declared the method differently. Is this proper?

    Posted February 26, 2023 10:30am by Samuel Kleos
    .a{fill-rule:evenodd;}techdegree
    Samuel Kleos
    Front End Web Development Techdegree Student 13,728 Points
    • JavaScript
    • Practice Object Basics in JavaScript
    • Practicing Object Basics
    • Practice Adding a Method to an Object Literal

    1 Answer

  • Jessie Doherty
    Jessie Doherty
    7,571 Points

    object literal question

    Posted May 7, 2022 1:19am by Jessie Doherty
    Jessie Doherty
    7,571 Points
    • JavaScript
    • Practice Object Basics in JavaScript
    • Practicing Object Basics
    • Practice Adding a Method to an Object Literal

    1 Answer

  • ja5on
    ja5on
    10,338 Points

    Having to cheat online copy paste question into google Plus no workspaces available on this entire part of the course

    Posted May 27, 2021 10:43am by ja5on
    ja5on
    10,338 Points
    • JavaScript
    • Practice Object Basics in JavaScript
    • Practicing Object Basics
    • Practice Adding a Method to an Object Literal

    2 Answers

  • Kylie Soderblom
    Kylie Soderblom
    3,890 Points

    Your countWords() method is not returning the correct number of words.

    Posted May 19, 2021 1:51am by Kylie Soderblom
    Kylie Soderblom
    3,890 Points
    • JavaScript
    • Practice Object Basics in JavaScript
    • Practicing Object Basics
    • Practice Adding a Method to an Object Literal

    1 Answer

  • Adrian Kucman
    Adrian Kucman
    10,654 Points

    Adding a method to an object literal - error unexpected identifier

    Posted April 17, 2021 9:39am by Adrian Kucman
    Adrian Kucman
    10,654 Points
    • JavaScript
    • Practice Object Basics in JavaScript
    • Practicing Object Basics
    • Practice Adding a Method to an Object Literal

    1 Answer

  • Taylor Hall
    seal-mask
    .a{fill-rule:evenodd;}techdegree seal-36
    Taylor Hall
    Front End Web Development Techdegree Graduate 14,496 Points

    I don't think the previous videos have been good enough to prepare us for this challenge.

    Posted November 29, 2020 9:58am by Taylor Hall
    .a{fill-rule:evenodd;}techdegree seal-36
    Taylor Hall
    Front End Web Development Techdegree Graduate 14,496 Points
    • JavaScript
    • Practice Object Basics in JavaScript
    • Practicing Object Basics
    • Practice Adding a Method to an Object Literal

    0 Answers

  • Umar Ijaz
    PLUS
    Umar Ijaz
    Courses Plus Student 7,278 Points

    What counts as a word?

    Posted October 18, 2020 10:15pm by Umar Ijaz
    Umar Ijaz
    Courses Plus Student 7,278 Points
    • JavaScript
    • Practice Object Basics in JavaScript
    • Practicing Object Basics
    • Practice Adding a Method to an Object Literal

    1 Answer

  • Trevon Allen
    Trevon Allen
    7,902 Points

    Your countWords() method is not returning the correct number of words.

    Posted September 6, 2020 5:08am by Trevon Allen
    Trevon Allen
    7,902 Points
    • JavaScript
    • Practice Object Basics in JavaScript
    • Practicing Object Basics
    • Practice Adding a Method to an Object Literal

    1 Answer

  • Richard Preske
    PLUS
    Richard Preske
    Courses Plus Student 4,356 Points

    countWords issue

    Posted May 5, 2020 4:51pm by Richard Preske
    Richard Preske
    Courses Plus Student 4,356 Points
    • JavaScript
    • Practice Object Basics in JavaScript
    • Practicing Object Basics
    • Practice Adding a Method to an Object Literal

    1 Answer

  • Alex Shah
    Alex Shah
    5,420 Points

    Add a method to the object literal called countWords(). countWords() should return the number of individual words in the

    Posted April 16, 2020 2:52pm by Alex Shah
    Alex Shah
    5,420 Points
    • JavaScript
    • Practice Object Basics in JavaScript
    • Practicing Object Basics
    • Practice Adding a Method to an Object Literal

    3 Answers

  • Christian Delos Reyes
    Christian Delos Reyes
    9,199 Points

    I have the same code, but mine doesn't work.

    Posted September 18, 2019 4:26pm by Christian Delos Reyes
    Christian Delos Reyes
    9,199 Points
    • JavaScript
    • Practice Object Basics in JavaScript
    • Practicing Object Basics
    • Practice Adding a Method to an Object Literal

    1 Answer

  • Stan Dav
    Stan Dav
    3,213 Points

    Hello, why my code is returning error Bummer: Cannot read property 'split' of undefined

    Posted August 15, 2019 8:27am by Stan Dav
    Stan Dav
    3,213 Points
    • JavaScript
    • Practice Object Basics in JavaScript
    • Practicing Object Basics
    • Practice Adding a Method to an Object Literal

    1 Answer

  • James Viavattine
    James Viavattine
    4,926 Points

    What am I doing wrong here?

    Posted May 4, 2019 1:15am by James Viavattine
    James Viavattine
    4,926 Points
    • JavaScript
    • Practice Object Basics in JavaScript
    • Practicing Object Basics
    • Practice Adding a Method to an Object Literal

    1 Answer

  • toguchir
    toguchir
    6,541 Points

    I have typed in the exact solution from the next step and I am receiving an "Unexpected Identifier" Error

    Posted April 28, 2019 2:49pm by toguchir
    toguchir
    6,541 Points
    • JavaScript
    • Practice Object Basics in JavaScript
    • Practicing Object Basics
    • Practice Adding a Method to an Object Literal

    1 Answer

  • Alasdair Marchant
    Alasdair Marchant
    4,592 Points

    how do I count the number of words?

    Posted January 5, 2019 12:20pm by Alasdair Marchant
    Alasdair Marchant
    4,592 Points
    • JavaScript
    • Practice Object Basics in JavaScript
    • Practicing Object Basics
    • Practice Adding a Method to an Object Literal

    1 Answer

  • Marcell Ciszek
    Marcell Ciszek
    7,255 Points

    please help me with this code

    Posted September 28, 2018 4:23am by Marcell Ciszek
    Marcell Ciszek
    7,255 Points
    • JavaScript
    • Practice Object Basics in JavaScript
    • Practicing Object Basics
    • Practice Adding a Method to an Object Literal

    1 Answer

  • Edmundo Ruiz
    Edmundo Ruiz
    3,488 Points

    totally lost

    Posted September 22, 2018 8:53pm by Edmundo Ruiz
    Edmundo Ruiz
    3,488 Points
    • JavaScript
    • Practice Object Basics in JavaScript
    • Practicing Object Basics
    • Practice Adding a Method to an Object Literal

    2 Answers

  • Bravo Bravo
    Bravo Bravo
    489 Points

    Dunno what to do

    Posted September 13, 2018 3:37am by Bravo Bravo
    Bravo Bravo
    489 Points
    • JavaScript
    • Practice Object Basics in JavaScript
    • Practicing Object Basics
    • Practice Adding a Method to an Object Literal

    1 Answer

  • MARIA Quadri
    MARIA Quadri
    2,572 Points

    I'm stuck on this code.

    Posted September 11, 2018 11:35pm by MARIA Quadri
    MARIA Quadri
    2,572 Points
    • JavaScript
    • Practice Object Basics in JavaScript
    • Practicing Object Basics
    • Practice Adding a Method to an Object Literal

    4 Answers

  • Alexander Davison
    Alexander Davison
    65,469 Points

    Practice objects problem [SOLVED]

    Posted September 5, 2018 2:16pm by Alexander Davison
    Alexander Davison
    65,469 Points
    • JavaScript
    • Practice Object Basics in JavaScript
    • Practicing Object Basics
    • Practice Adding a Method to an Object Literal

    1 Answer

Posting to the forum is only allowed for members with active accounts.
Please sign in or sign up to post.

    Treehouse

  • About
  • Blog
  • Careers
  • Community
  • Stories
  • Shop
  • Contact
  • Gift Card

See Full Catalogue

Techdegree

  • Front End Web Development
  • Full Stack JavaScript
  • Python Development
  • Data Analysis
  • UX Design

Tracks

  • Learn to Code for Beginners
  • Beginning Python
  • Beginning SQL
  • Beginning Java
  • ...see more

Courses

  • JavaScript Basics
  • Intro to HTML & CSS
  • Python Basics
  • CSS Layout
  • ...see more

Explore

  • Plans
  • Affiliates
  • Perks
  • Free Treehouse Near Me
  • Treehouse for Libraries
  • Treehouse for Businesses
  • Twitter
  • YouTube
  • Facebook
  • LinkedIn
  • Instagram
Terms & Conditions | Privacy

© 2025 Treehouse Island, Inc.