← HTML basics test lesson New set →

HTML Worksheet: Practice Test

HTML and CSS lesson 10: HTML basics test · Set 939 · 40 questions
TalentJR

Code tip (Read the code like a browser): Find the topic of the question: tags, headings, lists, links, images, structure or comments. Read the code line by line, the way a browser would. Count carefully: tags opened and closed, items, lines, paragraphs.

NameDateTime takenScore ___ / 40
  1. 1.True or false: <ol> lists things in any order. (a) False (b) True
  2. 2.🔍 One closing tag is missing. Which one?
    <i>The red kite</i>
    <u>My pets</u>
    <strong>Hello, world!
    (a) </strong> (b) </i> (c) </u> (d) </p>
  3. 3.🔠 Which heading shows the SMALLEST text: <h2>, <h3>, <h5> or <h1>? (a) <h1> (b) <h5> (c) <h2> (d) <h3>
  4. 4.🔢 In a basic web page file, which comes first: “<body>” or “</html>”? (a) </html> (b) <body>
  5. 5.🌐 Which one has an address bar? (a) a web browser (b) a code editor (c) a web server
  6. 6.🏷️ Is </h1> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
  7. 7.💬 How many paragraphs show on the page?
    <p>I love mangoes.</p>
    <p>Rain today</p>
    <!-- <p>Hello, world!</p> -->
    <p>My pets</p>
    <!-- <p>Fun facts</p> -->
  8. 8.💬 How many paragraphs show on the page?
    <p>I love mangoes.</p>
    <p>Cricket is fun.</p>
    <p>The red kite</p>
    <!-- <p>Hello, world!</p> -->
    <!-- <p>Our school trip</p> -->
  9. 9.🖼️ How many pixels wide is the picture drawn?
    <img src="bus.jpg" alt="Our school bus" width="300">
  10. 10.🔗 Where does this link open?
    <a href="https://example.com" target="_blank">Contact us</a>
    (a) in a new tab (b) in the same tab
  11. 11.🔠 How many heading levels does HTML have? (a) 10 (b) 6 (c) 4 (d) 3
  12. 12.🔠 How many <h1> headings should a page usually have? (a) 1 (b) 3 (c) 10 (d) 6
  13. 13.📋 What number does the browser show next to “Orange”?
    <ol>
      <li>Jamun</li>
      <li>Orange</li>
      <li>Papaya</li>
      <li>Mango</li>
      <li>Grapes</li>
    </ol>
  14. 14.True or false: HTML on its own can count button clicks. (a) True (b) False
  15. 15.📋 Does this list show bullets or numbers?
    <ul>
      <li>Litchi</li>
      <li>Banana</li>
      <li>Grapes</li>
    </ul>
    (a) numbers (b) bullets
  16. 16.📋 What number does the browser show next to “Papaya”?
    <ol start="3">
      <li>Orange</li>
      <li>Jamun</li>
      <li>Litchi</li>
      <li>Papaya</li>
      <li>Mango</li>
    </ol>
  17. 17.💬 Which text will NOT show on the page?
    <p>My best friend</p>
    <!-- <p>Rain today</p> -->
    <p>The red kite</p>
    <p>Fun facts</p>
    (a) Rain today (b) The red kite (c) My best friend (d) Fun facts
  18. 18.🔠 Which heading shows the SMALLEST text: <h5>, <h6>, <h2> or <h1>? (a) <h6> (b) <h1> (c) <h5> (d) <h2>
  19. 19.🔗 Which words do you click on?
    <a href="news.html">Art corner</a>
    (a) School news (b) href (c) news.html (d) Art corner
  20. 20.📝 How many paragraphs does this code make?
    <p>The red kite</p>
    <p>Our school trip</p>
    <p>Cricket is fun.</p>
    <h2>I love mangoes.</h2>
    <p>Fun facts</p>
    <p>Fun facts</p>
  21. 21.📄 What does the browser tab show for this page?
    <!DOCTYPE html>
    <html>
    <head>
      <title>Art Gallery</title>
    </head>
    <body>
      <h1>My drawings</h1>
      <p>We won by 5 runs.</p>
    </body>
    </html>
    (a) My drawings (b) Art Gallery (c) index.html (d) We won by 5 runs.
  22. 22.🖼️ Does <img> need a closing tag? (a) Yes (b) No
  23. 23.🔠 Which heading shows the SMALLEST text: <h5>, <h3>, <h6> or <h1>? (a) <h3> (b) <h6> (c) <h1> (d) <h5>
  24. 24.📋 Which list tag is an unordered list? (a) <li> (b) <ul> (c) <ol>
  25. 25.True or false: a web browser sends pages over the net. (a) False (b) True
  26. 26.💬 How does an HTML comment end? (a) --> (b) >> (c) */ (d) //
  27. 27.📋 Which list suits a shopping list in any order? (a) <hr> (b) <ul> (c) <br> (d) <ol>
  28. 28.🏷️ Which is the closing tag for <p>? (a) <p/> (b) <\p> (c) <p> (d) </p>
  29. 29.🔠 Which heading shows the BIGGEST text: <h2>, <h5>, <h3> or <h4>? (a) <h2> (b) <h5> (c) <h4> (d) <h3>
  30. 30.💬 How does an HTML comment start? (a) /* (b) // (c) # (d) <!--
  31. 31.True or false: in <img>, alt sets how tall it is. (a) False (b) True
  32. 32.📄 Where does <meta charset="utf-8"> go: in the head or in the body? (a) in the body (b) in the head
  33. 33.🔗 Where does this link open?
    <a href="news.html">Contact us</a>
    (a) in a new tab (b) in the same tab
  34. 34.📄 Which part holds everything you see on the page? (a) the head (b) the doctype (c) the body (d) the title
  35. 35.🔗 Which address opens when you click this link?
    <a href="maths.html">About us</a>
    (a) maths.html (b) About us (c) art.html (d) news.html
  36. 36.🔠 How many headings are in this code?
    <h1>Hello, world!</h1>
    <p>Fun facts</p>
    <h4>My pets</h4>
    <p>My best friend</p>
    <p>Hello, world!</p>
  37. 37.🏷️ Every HTML tag starts with which sign? (a) { (b) < (c) ( (d) [
  38. 38.🔠 Which heading shows the BIGGEST text: <h4>, <h5>, <h1> or <h2>? (a) <h1> (b) <h5> (c) <h4> (d) <h2>
  39. 39.🔗 Where does this link open?
    <a href="games.html" target="_blank">About us</a>
    (a) in a new tab (b) in the same tab
  40. 40.Which of these goes in the head? (a) <table> (b) <link rel="stylesheet"> (c) <ul> (d) <h1>

Answer key

  1. False
  2. </strong>
  3. <h5>
  4. <body>
  5. a web browser
  6. a closing tag
  7. 3
  8. 3
  9. 300
  10. in a new tab
  11. 6
  12. 1
  13. 2
  14. False
  15. bullets
  16. 6
  17. Rain today
  18. <h6>
  19. Art corner
  20. 5
  21. Art Gallery
  22. No
  23. <h6>
  24. <ul>
  25. False
  26. -->
  27. <ul>
  28. </p>
  29. <h2>
  30. <!--
  31. False
  32. in the head
  33. in the same tab
  34. the body
  35. maths.html
  36. 2
  37. <
  38. <h1>
  39. in a new tab
  40. <link rel="stylesheet">

Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids