1 00:00:00,390 --> 00:00:04,590 All right, it's time to put your knowledge of JavaScript objects to the test. 2 00:00:04,590 --> 00:00:09,040 In this practice challenge, you'll use JavaScript loops, arrays, and objects to 3 00:00:09,040 --> 00:00:13,120 create a script that builds a pet directory then displays it on the page. 4 00:00:13,120 --> 00:00:14,800 This is what it's gonna look like. 5 00:00:14,800 --> 00:00:19,170 To get started, launch the new workspace with this video, or open the challenge and 6 00:00:19,170 --> 00:00:22,178 the project files using your preferred text editor. 7 00:00:22,178 --> 00:00:27,030 The file pets.js is already linked to index.html and 8 00:00:27,030 --> 00:00:30,280 contains a comment providing instructions for this challenge. 9 00:00:30,280 --> 00:00:32,250 This is a two step challenge. 10 00:00:32,250 --> 00:00:37,430 For this first step, you'll create a data structure to hold information about pets. 11 00:00:37,430 --> 00:00:40,050 This might be an array named pets, for instance. 12 00:00:40,050 --> 00:00:42,375 The array should contain a list of objects. 13 00:00:42,375 --> 00:00:45,014 Each object should represent a pet and 14 00:00:45,014 --> 00:00:50,250 needs to have the following properties, name, type, and breed. 15 00:00:50,250 --> 00:00:53,630 Also an age property that points to the pet's age, so 16 00:00:53,630 --> 00:00:58,150 it should be a number value, and a property named photo that's assigned 17 00:00:58,150 --> 00:01:03,180 a string containing one of the image file names located inside the image folder. 18 00:01:03,180 --> 00:01:07,450 For example pug.jpg, golden.jpg, and so on. 19 00:01:07,450 --> 00:01:10,710 You'll need to create at least five pet objects. 20 00:01:10,710 --> 00:01:14,480 In the next video, I'll show you my solution to this part of the challenge. 21 00:01:14,480 --> 00:01:15,460 Good luck and have fun.