JavaScript Objects Worksheet
Question 1
What makes up an object (what does an object consist of)?
An object consists of properties, which are made up of key–value pairs.
Question 2
What are two different types of notations that you can use when working with the properites of objects?
Dot notation (object.property) and bracket notation (object["property"]).
Question 3
Why are objects an important data type in JavaScript?
Objects are important because they allow you to store and organize related data together, making programs easier to manage and work with.
Question 4
When creating an object, what character is used to separate property names from their values?
A colon ( : ) separates property names from values.
Question 5
When creating an object, what character is used to separate the property/value pairs in an object?
A comma ( , ) separates property/value pairs.
Question 6
What operator is used to access a property of an object?
The dot operator ( . ) is used to access a property.