The code from the Learn JavaScript the Hard Way module JavaScript Level 1 exercises. This is a mirror of the code I have in the book, so if you're struggling you can use this to compare against your attempts.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 

21 lines
870 B

exports.fruit = [
{kind: 'Apples', count: 12, rating: 'AAA'},
{kind: 'Oranges', count: 1, rating: 'B'},
{kind: 'Pears', count: 2, rating: 'A'},
{kind: 'Grapes', count: 14, rating: 'UR'}
];
exports.cars = [
{type: 'Cadillac', color: 'Black', size: 'Big', miles: 34500},
{type: 'Corvette', color: 'Red', size: 'Little', miles: 1000000},
{type: 'Ford', color: 'Blue', size: 'Medium', miles: 1234},
{type: 'BMW', color: 'White', size: 'Baby', miles: 7890}
];
exports.languages = [
{name: 'Python', speed: 'Slow', opinion: ['Terrible', 'Mush']},
{name: 'JavaScript', speed: 'Moderate', opinion: ['Alright', 'Bizarre']},
{name: 'Perl6', speed: 'Moderate', opinion: ['Fun', 'Weird']},
{name: 'C', speed: 'Fast', opinion: ['Annoying', 'Dangerous']},
{name: 'Forth', speed: 'Fast', opinion: ['Fun', 'Difficult']},
];