We Made A Friend! Question


Continuing the discussion from 6.) We Made A Friend! I am so rusty:

I'm a bit confused with this code, because how does the program know which argument to listen to? By that I mean, since there's two firstNames, which one will JavaScript fulfill with the first name?



One is a key, and one is a value.

firstName on the left is what you call, and firstName on the right is the value for it.

Have you done for loops yet? It's how with arrays, you use array[i] to call on parts of the array. i is the key, and the value returned is the value.


This is actually a good explanation.
Also sorry if my explanation of that code was shabby in the other topic.


Of course, it is. I made it.

edit: That makes me seem exuberantly cocky which I'm not.


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