var dogs = { Fido: "Mutt", Hunter: "Doberman", Snoopie: "Beagle" }; var myDog = "Hunter"; var myBreed = dogs[myDog]; console.log(myBreed); // "Doberman"