HTML Lists

Lists are used to group related items together in a structured format. HTML provides several types of lists:

1. Unordered List

Click Here

An unordered list is a collection of items where the order does not matter. It is created using the <ul> tag, and each item is defined with the <li> tag.

        
        <ul>
            <li>Item 1</li>
            <li>Item 2</li>
            <li>Item 3</li>
        </ul>
        
    

Exampal

2. Ordered List

Click Here

An ordered list is a collection of items where the order does matter. It is created using the <ol> tag, and each item is defined with the <li> tag.

        
        <ol>
            <li>First Item</li>
            <li>Second Item</li>
            <li>Third Item</li>
        </ol>
        
    

Output:-

  1. First Item
  2. Second Item
  3. Third Item

3. Definition List

Click Here

A definition list is used to define terms and their descriptions. It is created using the <dl>, <dt>, and <dd> tags.

        
        <dl>
            <dt>Term 1</dt>
            <dd>Definition of Term 1</dd>
            <dt>Term 2</dt>
            <dd>Definition of Term 2</dd>
        </dl>
        
    

Output:-

Term 1
Definition of Term 1
Term 2
Definition of Term 2

Lists are essential for organizing content on web pages, making it easier for users to read and understand information.