What problems does this chapter introduce that cannot be solved with variable types such as strings or integers?
-Another variable type is required to store a list of values, and values of different data types (a more complicated data structure is required).
What variable type can be used in order to solve the problem of storing multiple values?
-Arrays can be used to store multiple values
What are properties in Javascript?
-they describe or define characteristics of values or data in the data structure
Which values do not have properties?
-Null and undefined
How can we access properties in a value (two ways)?
-1) use the dot operator and 2) or use properties in square brackets
What are methods?
-properties that contain functions
What are objects?
-are containers or variables that can hold many different data types
What problem do objects solve that cannot be solved with other value types weâve learned so far (such as integer, string, array, boolean etc)?
-Objects can hold as much datatypes as we required to store and process, in a sense it is limitless
How do you define an object?
-like you define any other variable by using braces
What can you say about the mutability of Javascript objects?
-some variables are immutable in JS (strings, numbers, booleans) so they can not be changed after they have been defined. Objects are mutable so the values they contain in the data structure can be changed
NEXT SET OF QUESTIONS
Why canât you add new properties to a string variable?
-they are immutable and can not be changed after they have been defined
What are rest parameters?
-Rest parameters accept any number of arguments.
What is serialisation and what is a use case of serialisation of data?
-Serialization converts data into a flat description of itself. This allows us to use JSON notation to convert data between data types, from string to the value it holds and vice versa.
What is JSON?
-JavaScript Object Notation is a notation for data storage and communication.
What are the differences between JSON and the way programmers write objects in plain Javascript?
-Properties should also be written inside double quotes. JSON only allow simple values expression like strings, numbers, arrays and booleans. âSo no function calls, bindings, or anything that involves actual computation.â