Tip: Choose Save as PDF in the print dialog to download. Use A4 paper size.
This Unordered lists (ul and li) worksheet is part of the HTML and CSS Journey journey. Print it as a booklet?
Shade in the A or B circle for each question.
Draw a line connecting each item on the left to its match on the right.
| Left column | Right column | |
|---|---|---|
| 1<ul> <li>Apples</li> <li>Bananas</li> </ul> | AThe first <li> is missing its closing tag - it should be <li>Apples</li> | |
| 2<nav> <ul> <li><a href="h.html">Home</a></li> </ul> </nav> | BA navigation menu using <ul> and <li> to wrap the links - the standard semantic pattern for navbars | |
| 3<ul> is the list container; <li> wraps every individual list item inside it | CA bulleted unordered list - <ul> is the container and each <li> is one bullet point item | |
| 4Direct children of <ul> must be <li> elements - not <p>, <div>, or plain text | DDirect children of <ul> must be <li>, not <p> - replace <p>Apples</p> with <li>Apples</li> | |
| 5<ul> <li>Apples<li> <li>Bananas</li> </ul> | E<ul> <li>Milk</li> <li>Eggs</li> </ul> | |
| 6<ul> <p>Apples</p> <li>Bananas</li> </ul> | F<ul> <li>One</li> <li>Two</li> <li>Three</li> </ul> |
Complete each line of code by filling in the missing parts.
Shade in the letter of the line that contains an error.
<ul> — An HTML element that creates an unordered (bulleted) list. Each item inside must be wrapped in an <li> element.<ul>
<li>Apples</li>
<li>Bananas</li>
</ul><ul>
<li>Coffee</li>
<li>Tea</li>
</ul><ul>
<li>Red</li>
<li>Blue</li>
</ul><ul>
<li>One</li>
<li>Two</li>
</ul><nav>
<ul>
<li>Home</li>
</ul>
</nav>