HTML Lists
There are many lists in HTML. The most commonly used lists are given below:
- <ul>
- <li>
- <ol>
<ul>:
<ul> stands for unordered list. <ul> also have closing tag <ul></ul>.
<li>:
<li> stands for list items. <li> also have a closing tag <li></li>. <li> use to make items under <ul>.
For Example:
<ul>
<li>Milk</li>
<li>Chocolate</li>
<li>Snacks</li>
</ul>
Output:
- Milk
- Chocolate
- Snacks
<ol>:
<ol> stands for ordered list. <ol>also have closing tag <ol></ol>. It makes list items under ordered list.
For Example:
<ul>
<ol>
<li>Ice Cream</li>
<li>Butter</li>
<li>Coke</li>
</ol>
</ul>
Output:
- Ice Cream
- Butter
- Coke
There are more list in HTML link is given below:
Comments
Post a Comment