Skip to content

Latest commit

 

History

History
12 lines (9 loc) · 347 Bytes

Challenge-Access-Array-Data-with-Indexes.md

File metadata and controls

12 lines (9 loc) · 347 Bytes

Access Array Data with Indexes

We can access the data inside arrays using indexes.

Array indexes are written in the same bracket notation that strings use, except that instead of specifying a character, they are specifying an entry in the array.

For example:

var array = [1,2,3];
array[0]; //equals 1
var data = array[1];