0
0
HTMLmarkup~20 mins

Nav element in HTML - Practice Problems & Coding Challenges

Choose your learning style9 modes available
Challenge - 5 Problems
🎖️
Nav Element Master
Get all challenges correct to earn this badge!
Test your skills under time pressure!
🧠 Conceptual
intermediate
1:30remaining
Purpose of the
What is the main purpose of the
ATo add a footer section at the bottom of the page.
BTo create a container for images and multimedia content.
CTo define a section containing navigation links for the website.
DTo style text with bold and italic effects.
Attempts:
2 left
💡 Hint
Think about what users use to move between pages on a website.
📝 Syntax
intermediate
2:00remaining
Correct Usage of
Which of the following HTML snippets correctly uses the
A<nav><p>Home</p><p>About</p></nav>
B<nav><span>Home</span><span>About</span></nav>
C<nav><div>Home</div><div>About</div></nav>
D<nav><ul><li><a href="home.html">Home</a></li><li><a href="about.html">About</a></li></ul></nav>
Attempts:
2 left
💡 Hint
Navigation links should be clickable and grouped in a list.
rendering
advanced
2:00remaining
Visual Result of a
What will you see in the browser when this HTML and CSS code runs?
HTML
<nav style="display:flex; gap:1rem;"><a href="#">Home</a><a href="#">Services</a><a href="#">Contact</a></nav>
ALinks arranged randomly with overlapping text.
BThree links arranged horizontally with space between them.
CLinks hidden because <nav> cannot use flexbox.
DThree links stacked vertically with no space.
Attempts:
2 left
💡 Hint
Flexbox with display:flex arranges children in a row by default.
accessibility
advanced
1:30remaining
Improving Accessibility of a
Which attribute improves accessibility by describing the purpose of a
Aaria-label="Main navigation"
Bstyle="color:blue"
Conclick="alert('nav clicked')"
Did="nav1"
Attempts:
2 left
💡 Hint
Screen readers use ARIA attributes to understand page sections.