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

🤑 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

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

  • 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
    • Showing results for:
    • JavaScript
    • Practice Object Basics in JavaScript
    • Practicing Object Basics
    • Practice Adding a Method to an Object Literal
    • Close
  • Janina Alvarez
    Janina Alvarez
    8,083 Points

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

    Posted on Jun 13, 2024 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 on Jul 31, 2023 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 on Feb 26, 2023 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 on May 7, 2022 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 on May 27, 2021 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 on May 19, 2021 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 on Apr 17, 2021 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 on Nov 29, 2020 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 on Oct 18, 2020 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 on Sep 6, 2020 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 on May 5, 2020 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 on Apr 16, 2020 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 on Sep 18, 2019 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 on Aug 15, 2019 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 on May 4, 2019 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 on Apr 28, 2019 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 on Jan 5, 2019 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 on Sep 28, 2018 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 on Sep 22, 2018 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 on Sep 13, 2018 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 on Sep 11, 2018 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 on Sep 5, 2018 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.