numbers
which can hold up-to 8 float64
values.songs
which can hold up-to 5 string
values []
with an index that begins at 0
0
and not 1
output: invalid array index 7 (out of bounds for 7-element array)
...
” appears in place of the length, the array length is determined by the number of elementslen()
function to calculate length of array being iterated.for...range
to loop over an array. range
returns each array index and item. ==
and !=
. Remember, for arrays to be to of similar types, they need to store same type of data as well as their length must be same.