For Loop prints out every letter of an array


I want this code:

var name = ["Natsu", "Ichigo", "Naruto", "Saitama", "Keichi"];
var i;

for (i = 0; i < name.length; i++) {

to print out the names, but instead it prints out every single letter of the names...
Whats wrong with it?


There is no problem in these lines of code. Try to run it here. You will see that the names are printed on console correctly.

If this is only one part of your code, maybe the problem is elsewhere.


There is a problem with the Code.

name is a reserved word in javascript.

If you try here code in your browser console you will see the result she explained.
Change the varibale name to something else you get the right result.


Replace "name" variable by "names" as per required in exercise.


You are right. It's build-in property.