174 WDB Arrays
174 WDB Arrays
JS Arrays
OUR FIRST DATA STRUCTURE
ARRAYS
Ordered collections of values.
List of comments on IG post
Collection of levels in a game
Songs in a playlist
Creating Arrays
PLEASE DROP BY AND SEE ME!
ARRAYS ARE INDEXED
Doc Dopey Bashful Grumpy Sneezy Sleepy Happy
0 1 2 3 4 5 6
Each element has a corresponding index
(counting starts at 0)
Arrays Are Indexed
Modifying Arrays
ARRAY METHODS
AND
ARRAYS
WHY DO PEOPLE USE CONST WITH ARRAYS??
THE VALUES CAN CHANGE
AS LONG AS THE REFERENCE REMAINS THE SAME
myEggs
THE VALUES CAN CHANGE
AS LONG AS THE REFERENCE REMAINS THE SAME
myEggs
THE VALUES CAN CHANGE
AS LONG AS THE REFERENCE REMAINS THE SAME
myEggs
THE VALUES CAN CHANGE
AS LONG AS THE REFERENCE REMAINS THE SAME
myEggs
NESTED ARRAYS
We can store arrays inside other arrays!
NESTED
ARRAYS