3. Array properties


#1



I don't quite understand what I have to do and what is wrong with my code. This is the question of the topic:

If you remember, arrays have a property in common with strings: they can both use .length. When you call .length on an array, it returns the number of elements that array has.

Instructions
Under your existing code, log the number of elements in languages to the console.


Error message:

Oops, try again. Make sure to log the number of elements the languages array has to the console.

My code:

var languges = ["HTML", "CSS", "JavaScript", "Python", "Ruby"];
var log = languages[2];
//console.log(log);
for (var i = 0; i < languages.length; i++) {
    console.log(languages[i]);
}


#2

you need to log something to the console, which means you need to console.log(), what do you need to log? The length of languages (languages.length)


#3

This post was flagged by the community and is temporarily hidden.


#4

nice catch of the typo on line 1, very good point.