This runs differently in chrome vs codeacademy


It should print each name only once, right?



++++ why second display of last Item
It is the Javascript interpreter which is running in this course-environment,
it display's the last non-displayed action...

You will also encounter this, when you are doing a return-statement
as last action...
You could counter this by using a
console.log( " " ); as last statement....

In some sections of this course, the course-checker Display's data
this you could then identify by placing to EXTRA code-line's:
console.log( "== My End ==" );
console.log( "== All that is displayed now, is the course-checker ==" );


I tried your suggestion, putting console.log( " " ); as last statement, and it didn't work.

besides, I'm writing exactly what they're asking me to, and I can't get through this part, which is really frustrating because I know it's correct, and I'm 90% done with the javascript lessons, this is the only thing holding me back.

It says "Oops, try again. It looks like your list function isn't printing the right output."


You created an Array containing 2 Objects

 friends = [ { object1 }, { object2 } ];

I think they wanted

-1 Create an object called friends. Feel free to use either object literal notation or the object constructor.
-2 Add a few empty objects to your friends object. Make sure you add a friend named 'bill' and a friend named 'steve'.
-3 Give each of your friends a firstName, lastName, and number. The value for each of these should be a string (check the Hint if you need help). Make sure bill's first name is "Bill" and steve's first name is "Steve" (again, note the capitalization).
-4 Add an address property to each of your friends and set that property equal to an array value.
-5 Instructions

  • -1. Create a function list that takes a single parameter.
  • -2. In the body of the function, write a for/in loop.
  • -3. In the loop, use console.log to print out the key. (For example, if you only have bill and steve as entries, list should just print out "bill" and "steve".)



+++ friends list and search and for-in explained.
Look here for an explanation