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

What iterating and expression mean?

What iterating and expression mean in JavaScript?

1 Answer

Steven Parker
Steven Parker
243,318 Points

Here are some basic definitions:

"Iterating" means "doing something in a loop", for example: when you have a list of things and you want to print out the name of each one. Doing that would involve "iterating" over that list.

And "expression" is any group of names and/or symbols that together result in a value. For example: "12 + 7" is an expression that has a value of 19. It's not always possible to determine the exact value of an expression when reading (or writing) it (like: "randompic() + lower"), but it's enough to know that it will have one when the code is actually running.