Lists
Section 1: HTML: the page's contentLesson 1.3 · ⏱ 6 min
<ul> is a list with dots, and every item in it is <li>.
HTML
<h1>My favourite food</h1>
<ul>
<li>Koshari</li>
<li>Pizza</li>
<li>Mango</li>
</ul>
CSS
body { font-family: Tahoma; }
🖥️ The page in Robo Web:

📌 Another example: a list inside a list
A numbered list of steps, and inside one step a list with dots.
HTML
<h2>We make juice</h2>
<ol>
<li>Wash the fruit</li>
<li>Cut it:
<ul>
<li>Banana</li>
<li>Strawberry</li>
</ul>
</li>
<li>Mix it in the blender</li>
</ol>
CSS
body { font-family: Tahoma, sans-serif; }
🖥️ The page in Robo Web:

✍️ Practise
Lists.
✍️ Practise here in the lesson✖ Close the labor open the lab in a new page ↗
🎯 Challenge yourself
Easy
A ul list with 3 colours.
👀 Show the solution🙈 Hide the solution
HTML
<ul>
<li>Red</li>
<li>Green</li>
<li>Blue</li>
</ul>
CSS
body { font-family: Tahoma, sans-serif; }
🖥️ The page in Robo Web:

Result: three dots.
Medium
An ol numbered list with five steps for waking up.
👀 Show the solution🙈 Hide the solution
HTML
<ol>
<li>I wake up</li>
<li>I wash my face</li>
<li>I have breakfast</li>
<li>I get dressed</li>
<li>I go to school</li>
</ol>
CSS
body { font-family: Tahoma, sans-serif; }
🖥️ The page in Robo Web:

Result: five steps numbered 1 to 5.
Hard
A list in two parts: “Animals” and “Birds”, with a list under each part.
👀 Show the solution🙈 Hide the solution
HTML
<ul>
<li>Animals
<ul><li>Lion</li><li>Elephant</li></ul>
</li>
<li>Birds
<ul><li>Eagle</li><li>Duck</li></ul>
</li>
</ul>
CSS
body { font-family: Tahoma, sans-serif; }
🖥️ The page in Robo Web:

Result: two parts, with two under each.

