Guest User

Untitled

a guest
Jun 24th, 2018
205
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. var bob = {
  2.     firstName: "Bob",
  3.     lastName: "Jones",
  4.    
  5.     phoneNumber: "(650) 777 - 7777",
  6.     email: "bob.jones@example.com"
  7. };
  8.  
  9. var mary = {
  10.     firstName: "Mary",
  11.     lastName: "Johnson",
  12.    
  13.     phoneNumber: "(650) 888 - 8888",
  14.     email: "mary.johnson@example.com"
  15. };
  16.  
  17. var contacts = [bob, mary];
  18.  
  19.  
  20. printPerson (person){
  21.     console.log(person.firstName + " " + person.lastName);
  22. };
  23. printPerson(contacts[0]);
  24. printPerson(contacts[1]);
Add Comment
Please, Sign In to add comment