I have an array as follows:
var str_array=["hello","world"]
How to get length of string when string are there in array? I just want to get length of string "hello" and then "world" inside a loop. This is what I've tried:
for (var i=0; i<= str_array[0].length; i++){
alert(str_array[i].starAt(i));
}
I get error message
TypeError: Cannot read property 'length' of undefined