Difference between revisions of "Defining Objects"

From rbachwiki
Jump to navigation Jump to search
Line 10: Line 10:
  for(var item in comptype){
  for(var item in comptype){
  console.log(item + " - " + comptype[item]);
  console.log(item + " - " + comptype[item]);
==[[#top|Back To Top]]-[[Main_Page| Home]] - [[Java Script|Category]]==

Revision as of 19:23, 25 October 2016

 var comptype = {
 brand: 'ibm',
 ram: '128 Gigs',
 hdrive: '1 Terabyte'

}

Loop through items

for(var item in comptype){
console.log(item + " - " + comptype[item]);

Back To Top- Home - Category