Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

JavaScript JavaScript Basics (Retired) Making Decisions with Conditional Statements The Conditional Challenge Solution

Zaq Dayton
Zaq Dayton
2,244 Points

How come the instructor uses .toUpperCase() with parentheses in the first condition, but uses .toUpperCase after?

I was just wondering the reason behind why the instructor uses the .toUpperCase() method with the parentheses in the first conditional value, but after that the rest of the .toUpperCase methods do not include the open and close parentheses? Thanks in advance!

1 Answer

It's an error, you must include the parenthesis to use the toUpperCase method. If you tried to run that code, it would give you an "unexpected identifier" error.

Zaq Dayton
Zaq Dayton
2,244 Points

Thanks! That's what I was thinking, just making sure!