JAVASCRIPT CLIMBSChapter 3 · JS Collections & Loops
Labeled structures
JavaScript objects store key-value properties. You can declare them using curly braces {} and retrieve values using dot notation or bracket notation.
Worked example
How it reads
star.nameuses dot notation to read the name property.star["mag"]uses bracket notation to retrieve the magnitude.

Cloud tip: Objects are similar to Python dictionaries. Use keys (which must be valid strings) to store data.


