HTML5: How to define an unordered list?
Solution:
HTML Code:
<!DOCTYPE html><!-- Define document type as HTML -->
<html><!-- Begin HTML document -->
<head><!-- Start of document header -->
<meta charset="utf-8"><!-- Define character encoding -->
<title>How to define an unordered list</title><!-- Title of the HTML page -->
</head><!-- End of document header -->
<body><!-- Start of document body -->
<ul><!-- Begin unordered list -->
<li>Tutorials</li><!-- List item: Tutorials -->
<li>Online Practice Editor </li><!-- List item: Online Practice Editor -->
<li>Examples</li><!-- List item: Examples -->
<li>References</li><!-- List item: References -->
<li>Videos</li><!-- List item: Videos -->
</ul><!-- End unordered list -->
</body><!-- End of document body -->
</html><!-- End of HTML document -->
Explanation:
- The HTML code defines an unordered list (<ul>) element, which is a bulleted list.
- Each list item (<li>) represents an item in the list.
- The list contains items such as "Tutorials", "Online Practice Editor", "Examples", "References", and "Videos".
Live Demo:
See the Pen ul-answer by w3resource (@w3resource) on CodePen.
See the solution in the browser
Supported browser
Yes | Yes | Yes | Yes | Yes |
What is the difficulty level of this exercise?
Test your Programming skills with w3resource's quiz.
It will be nice if you may share this link in any developer community or anywhere else, from where other developers may find this content. Thanks.
https://w3resource.com/html-css-exercise/basic/ul-answer.php
- Weekly Trends and Language Statistics
- Weekly Trends and Language Statistics