Understanding array

Tell us what’s happening:
Why does the console show undefined for this code?
Your code so far


var ohArr = [1,2,3,"bank", 5.7, true]
var y = ohArr.lenght;
console.log(y);



**Your browser information:**

User Agent is: <code>Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/89.0.4389.82 Safari/537.36</code>.

check the spelling that you are using

1 Like

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.