0 1 00:00:00,540 --> 00:00:08,370 All right. Time for challenge 13. The goal of this challenge is such that when you head over to the compose 1 2 00:00:08,370 --> 00:00:16,890 page and you create a number of posts, one is called Day 1, one's called Day 2, one's called day 3 and then you hit publish 2 3 00:00:16,980 --> 00:00:18,780 and you publish all three posts, 3 4 00:00:18,780 --> 00:00:20,450 you have to do this three times. 4 5 00:00:20,550 --> 00:00:28,780 But at this point if you head over to your terminal you should see each of the post titles printed out. 5 6 00:00:28,860 --> 00:00:35,040 So the first time when I created a post, it only printed out the first title, the second time it printed 6 7 00:00:35,130 --> 00:00:41,920 the first and the second title and a third time just now it printed all three titles that I've created. 7 8 00:00:42,060 --> 00:00:51,200 This is no longer the entire posts array but it's actually posting each and every title inside the array. 8 9 00:00:51,540 --> 00:00:58,860 So in order to do this, you'll need to write a FOR loop inside the homeeks that loops through this 9 10 00:00:58,920 --> 00:01:04,190 post array and console logs each and every title, 10 11 00:01:04,320 --> 00:01:11,520 the titles of each of these posts. And to test it you should have a minimum of two posts so that you 11 12 00:01:11,520 --> 00:01:18,800 can make sure that you are indeed printing out all of the titles inside the posts array. Pause the video and complete 12 13 00:01:18,830 --> 00:01:20,400 this challenge. 13 14 00:01:20,450 --> 00:01:22,990 All right here comes my first hint. 14 15 00:01:23,030 --> 00:01:25,510 Now remember that to create a FOR loop 15 16 00:01:25,550 --> 00:01:33,350 this is the standard format. And you first start off from zero and then you put an upper bound when you 16 17 00:01:33,350 --> 00:01:35,060 want the FOR loop to stop, 17 18 00:01:35,060 --> 00:01:37,470 so how many times do you want the loop to run. 18 19 00:01:37,880 --> 00:01:43,310 Then you increment through the FOR loop one at a time and that allows you to tap into this thing called 19 20 00:01:43,410 --> 00:01:48,880 i which will change from 0 to 1 to 2 until the upper bound. 20 21 00:01:48,980 --> 00:01:55,160 And this means that if you add an array then you can tap into the zeroth item, the first, the second, the 21 22 00:01:55,160 --> 00:02:00,920 third and that means you can loop through the array and do whatever it is you need with each of the 22 23 00:02:00,920 --> 00:02:02,940 items inside the array. 23 24 00:02:03,290 --> 00:02:08,210 So see if that's enough of a hint for you to be able to complete this challenge. 24 25 00:02:09,240 --> 00:02:18,570 Now my second hnt is that in our case, the upper bound inside our FOR loop will be the number of posts inside 25 26 00:02:18,630 --> 00:02:19,880 our posts array. 26 27 00:02:20,130 --> 00:02:26,900 If there's only one item inside posts array then the upper bound will simply be one 27 28 00:02:27,210 --> 00:02:33,770 and if there's 10 items inside our posts array, then the upper bound will be 10. 28 29 00:02:33,840 --> 00:02:40,270 In order to do that dynamically remember you can tap into array.lent,h so posts.length. 29 30 00:02:40,440 --> 00:02:42,470 I hope that's enough of a hint for you to be able to 30 31 00:02:42,480 --> 00:02:44,100 now complete the challenge.