Ordered and Unordered Lists in HTML

31
Mr. Coder | 26-Oct-2024
Description

Sample Code : Navigation bar using ul tag

Ordered list in HTML displays the sequence of numbers in front of each list item. Its code example is shown below.
<ol>
   <li>Motorbike</li>
   <li>Car</li>
   <li>Bus</li>
   <li>Truck</li>
</ol>


Output :

  1. Motorbike
  2. Car
  3. Bus
  4. Truck


Unordered list in HTML displays the bullet in front of each list item. Its code example is shown below.
<ul>
   <li>Motorbike</li>
   <li>Car</li>
   <li>Bus</li>
   <li>Truck</li>
</ul>


Output :

  • Motorbike
  • Car
  • Bus
  • Truck

Comments
Load more comments.
Please Login or Sign up to comment.
logo
facebook youtube