Skip to content

Instantly share code, notes, and snippets.

@tanyagupta
Last active November 4, 2016 17:21
Show Gist options
  • Save tanyagupta/3c431c4e2aee81789048b1421688496e to your computer and use it in GitHub Desktop.
Save tanyagupta/3c431c4e2aee81789048b1421688496e to your computer and use it in GitHub Desktop.
Tester function for efficient and inefficient function
function get_data_set(which){
var all_data_set={
basic:[
{make: "Jeep",model: "Cherokee",trim:"Sport 4dr Front-wheel Drive",year:"2016",wheel:{wheel_size:"17 x 7.5",
wheel_metal:"Aluminum"}},
{make: "Jeep",model: "Compass",trim:"Latitude 4dr Front-wheel Drive",year:"2014",
wheel:{wheel_metal:"Steel"}},
{make: "Jeep",model: "Patriot",trim:"Sport 4dr 4x4"},
{make: "Jeep",model: "Wrangler",trim:"Sahara 2dr 4x4",year: "2015"}
]
}
var res = all_data_set[which]
return res;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment