Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialMiron Kiselev
1,184 PointsCode Challenge Difficulty
I am having difficulty with task 3 on the codechallenge
4 Answers
Laura Cressman
12,548 PointsHi Miron,
I went to the code challenge, and I'm assuming you are referring to the task where you add an unordered list below the ordered list. To do that, you simply add empty unordered list tags, like <ul></ul>
. The instructions also say to not delete the ordered list, so that could be where you are running into problems. Try something like I'm posting below, and let me know if that helps!
```<!DOCTYPE html> <html> <head> <title>HTML Lists Challenge</title> </head> <body>
<h1>HTML Lists Challenge</h1>
<!-- Write your code below -->
<ol>
<li>Stop</li>
<li>Drop</li>
<li>Roll</li>
</ol>
<ul>
</ul>
</body> </html>
Miron Kiselev
1,184 PointsThanks, however I am talking about when you put an unordered list into an ordered one. Thanks.
Laura Cressman
12,548 PointsIn that case, you simply next the <ul></ul>
tags inside the ordered list. Check out the example below and let me know if that makes sense :)
<ol>
<li>Bananas</li>
<li>Apples</li>
<ul>
<li>Red</li>
<li>Green</li>
<li>Yellow</li>
</ul>
<li>Strawberries</li>
</ol>
Miron Kiselev
1,184 PointsI did exactly that but it said I made a mistake!
Laura Cressman
12,548 PointsWould you mind copying and pasting your code over?
Miron Kiselev
1,184 Points<!DOCTYPE html> <html> <head> <title>HTML Lists Challenge</title> </head> <body>
<h1>HTML Lists Challenge</h1>
<!-- Write your code below -->
<ul>
<li>Shapes
<ol>
<li></li>
<li></li>
</ol>
</li>
<li>Colors</li>
</ul>
<ol>
<li>Stop</li>
<li>Drop</li>
<li>Roll</li>
</ol>
</body> </html>
Laura Cressman
12,548 PointsI see that you are missing the closing </li> tag after the word "shapes", and instead you have it after the </ol> tag. Can you move the closing </li> tag so it is after shapes? This would look something like this.
<!-- Write your code below -->
<ul>
<li>Shapes</li>
<ol>
<li></li>
<li></li>
</ol>
<li>Colors</li>
</ul>
<ol>
<li>Stop</li>
<li>Drop</li>
<li>Roll</li>
</ol>
Miron Kiselev
1,184 PointsI did that but it says task two is no longer functioning.
Laura Cressman
12,548 PointsOK, I think I found the bug. It wouldn't let me pass unless the Stop, Drop, and Roll list came before the Shapes and Colors list. Once I tried this, however, it worked. It seems like you understand the concept, but just need to pass the challenge. Try this and let me know if it works.
<ol>
<li>Stop</li>
<li>Drop</li>
<li>Roll</li>
</ol>
<ul>
<li>Shapes
<ol>
<li>Square</li>
<li>Circle</li>
</ol>
</li>
<li>Colors</li>
</ul>
Miron Kiselev
1,184 PointsYeah thanks a lot, it works!
Laura Cressman
12,548 PointsYou're welcome:)
James Barnett
39,199 PointsJames Barnett
39,199 PointsPost what code you have so far.