← HTML basics test lesson New set →

HTML Worksheet: Practice Test

HTML and CSS lesson 10: HTML basics test · Set 736 · 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.Which of these is true of a code editor? (a) hosts websites online (b) is where we type code (c) sends pages over the net (d) has an address bar
  2. 2.📄 Where does <a> go: in the head or in the body? (a) in the head (b) in the body
  3. 3.🔍 One closing tag is missing. Which one?
    <h2>Hello, world!
    <small>Fun facts</small>
    <i>Good morning!</i>
    (a) </i> (b) </h3> (c) </small> (d) </h2>
  4. 4.💬 How does an HTML comment start? (a) // (b) /* (c) <!-- (d) #
  5. 5.🔍 One closing tag is missing. Which one?
    <h2>Hello, world!</h2>
    <b>Fun facts</b>
    <u>Our school trip
    (a) </b> (b) </h3> (c) </u> (d) </h2>
  6. 6.📋 Which list shows the steps of a recipe best? (a) <ul> (b) <br> (c) <hr> (d) <ol>
  7. 7.🔠 Which heading shows the SMALLEST text: <h5>, <h2>, <h6> or <h1>? (a) <h6> (b) <h5> (c) <h1> (d) <h2>
  8. 8.💬 How does an HTML comment end? (a) */ (b) >> (c) --> (d) //
  9. 9.📄 Can HTML on its own keep a high score? (a) Yes (b) No
  10. 10.True or false: <img> goes in the head. (a) True (b) False
  11. 11.📄 Where does the text of <title> appear? (a) on the browser tab (b) in a big heading (c) nowhere (d) at the bottom
  12. 12.📝 How many paragraphs does this code make?
    <p>My best friend</p>
    <p>Rain today</p>
    <p>Hello, world!</p>
  13. 13.🏷️ Is </h1> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
  14. 14.📋 Which tag goes around each item of a list? (a) <ul> (b) <ol> (c) <li> (d) <p>
  15. 15.🏷️ What does a closing tag have that an opening tag does not? (a) a hash # (b) a slash / (c) a dot . (d) a dollar $
  16. 16.🌐 Which one sends pages over the net? (a) a web server (b) a code editor (c) a web browser
  17. 17.🔗 Which address opens when you click this link?
    <a href="quiz.html">Contact us</a>
    (a) games.html (b) about.html (c) quiz.html (d) Contact us
  18. 18.📋 Which list tag is one item of a list? (a) <li> (b) <ol> (c) <ul>
  19. 19.True or false: HTML on its own can pick a random number. (a) True (b) False
  20. 20.🔠 Which tag is the least important heading? (a) <h6> (b) <h1> (c) <p> (d) <h3>
  21. 21.🖼️ Does <img> need a closing tag? (a) Yes (b) No
  22. 22.Which of these is a closing tag? (a) <body> (b) </li> (c) <b> (d) <li>
  23. 23.🔠 How many headings are in this code?
    <h1>Good morning!</h1>
    <h2>Rain today</h2>
    <h3>My best friend</h3>
    <h4>Fun facts</h4>
    <h4>Hello, world!</h4>
  24. 24.🔗 Which words do you click on?
    <a href="games.html">Contact us</a>
    (a) href (b) games.html (c) Visit the site (d) Contact us
  25. 25.🔠 How many headings are in this code?
    <h1>My pets</h1>
    <h3>I love mangoes.</h3>
    <p>Cricket is fun.</p>
  26. 26.📄 Can HTML on its own count button clicks? (a) Yes (b) No
  27. 27.🔤 In “HTML”, what does the L stand for? (a) Laptop (b) Language (c) Link (d) Line
  28. 28.📄 Where does <p> go: in the head or in the body? (a) in the head (b) in the body
  29. 29.🔠 How many headings are in this code?
    <h1>I love mangoes.</h1>
    <p>Hello, world!</p>
    <p>My pets</p>
    <h2>Rain today</h2>
  30. 30.📋 Which list tag is an unordered list? (a) <ol> (b) <li> (c) <ul>
  31. 31.🔍 Which line is missing its closing tag?
    line 1: <strong>Fun facts</strong>
    line 2: <p>Our school trip
    line 3: <em>My best friend</em>
    (a) line 3 (b) line 1 (c) line 2
  32. 32.🔠 Which heading shows the SMALLEST text: <h5>, <h4>, <h3> or <h6>? (a) <h4> (b) <h5> (c) <h3> (d) <h6>
  33. 33.💬 How many paragraphs show on the page?
    <p>Rain today</p>
    <p>Cricket is fun.</p>
    <!-- <p>I love mangoes.</p> -->
  34. 34.🔠 How many headings are in this code?
    <h1>Our school trip</h1>
    <h2>Hello, world!</h2>
    <h4>My pets</h4>
  35. 35.🖼️ Which attribute of <img> names the picture file? (a) alt (b) src (c) height (d) width
  36. 36.💬 How many paragraphs show on the page?
    <p>Rain today</p>
    <!-- <p>Our school trip</p> -->
    <p>Hello, world!</p>
  37. 37.True or false: <li> lists steps in order. (a) False (b) True
  38. 38.🔠 Which heading shows the BIGGEST text: <h3>, <h5>, <h6> or <h2>? (a) <h3> (b) <h5> (c) <h6> (d) <h2>
  39. 39.Which of these goes in the body? (a) <table> (b) <title> (c) <style> (d) <meta charset="utf-8">
  40. 40.📋 Does this list show bullets or numbers?
    <ul>
      <li>Banana</li>
      <li>Litchi</li>
      <li>Papaya</li>
    </ul>
    (a) bullets (b) numbers

Answer key

  1. is where we type code
  2. in the body
  3. </h2>
  4. <!--
  5. </u>
  6. <ol>
  7. <h6>
  8. -->
  9. No
  10. False
  11. on the browser tab
  12. 3
  13. a closing tag
  14. <li>
  15. a slash /
  16. a web server
  17. quiz.html
  18. <li>
  19. False
  20. <h6>
  21. No
  22. </li>
  23. 5
  24. Contact us
  25. 2
  26. No
  27. Language
  28. in the body
  29. 2
  30. <ul>
  31. line 2
  32. <h6>
  33. 2
  34. 3
  35. src
  36. 2
  37. False
  38. <h2>
  39. <table>
  40. bullets

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