← HTML basics test lesson New set →

HTML Worksheet: Practice Test

HTML and CSS lesson 10: HTML basics test · Set 144 · 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 list suits a shopping list in any order? (a) <br> (b) <hr> (c) <ol> (d) <ul>
  2. 2.💬 How many paragraphs show on the page?
    <p>Cricket is fun.</p>
    <!-- <p>Our school trip</p> -->
    <p>I love mangoes.</p>
    <p>My pets</p>
  3. 3.📋 Which list tag shows bullet points? (a) <ul> (b) <ol> (c) <li>
  4. 4.📋 How many items does this list show?
    <ul>
      <li>Jamun</li>
      <li>Mango</li>
      <li>Guava</li>
    </ul>
  5. 5.🔠 How many headings are in this code?
    <h1>My best friend</h1>
    <h2>Fun facts</h2>
    <p>My pets</p>
    <h2>The red kite</h2>
  6. 6.Which of these goes in the head? (a) <style> (b) <img> (c) <p> (d) <a>
  7. 7.Which of these is true of a web server? (a) stores a website’s files (b) shows line numbers (c) saves our .html files (d) shows pages from the web
  8. 8.💬 Can anyone read your comments by viewing the page source? (a) Yes (b) No
  9. 9.True or false: <input> is an empty tag. (a) False (b) True
  10. 10.Which of these is an opening tag? (a) <li> (b) </title> (c) </b> (d) </body>
  11. 11.Which of these is an empty tag? (a) <p> (b) <input> (c) <h1> (d) <title>
  12. 12.🔠 Which heading shows the SMALLEST text: <h3>, <h5>, <h2> or <h6>? (a) <h2> (b) <h5> (c) <h3> (d) <h6>
  13. 13.🏷️ Is <li> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
  14. 14.🔍 Which line is missing its closing tag?
    line 1: <strong>My best friend</strong>
    line 2: <em>Hello, world!
    line 3: <b>Our school trip</b>
    (a) line 1 (b) line 3 (c) line 2
  15. 15.📋 Which list shows the steps of a recipe best? (a) <br> (b) <ul> (c) <hr> (d) <ol>
  16. 16.🔗 Which words do you click on?
    <a href="about.html">Play games</a>
    (a) About us (b) about.html (c) Play games (d) href
  17. 17.🔍 Which line is missing its closing tag?
    line 1: <small>Hello, world!
    line 2: <strong>Cricket is fun.</strong>
    line 3: <h2>The red kite</h2>
    (a) line 2 (b) line 1 (c) line 3
  18. 18.Which of these goes in the head? (a) <p> (b) <ul> (c) <link rel="stylesheet"> (d) <h1>
  19. 19.📋 Which list tag lists things in any order? (a) <li> (b) <ol> (c) <ul>
  20. 20.📄 What does the browser tab show for this page?
    <!DOCTYPE html>
    <html>
    <head>
      <title>Class 7 Blog</title>
    </head>
    <body>
      <h1>All about me</h1>
      <p>Mars is red.</p>
    </body>
    </html>
    (a) All about me (b) index.html (c) Class 7 Blog (d) Mars is red.
  21. 21.🔠 Which heading shows the BIGGEST text: <h1>, <h5>, <h2> or <h4>? (a) <h2> (b) <h4> (c) <h5> (d) <h1>
  22. 22.🏷️ HTML marks up text using ___. (a) pixels (b) wires (c) tags (d) keys
  23. 23.📝 How many paragraphs does this code make?
    <p>My pets</p>
    <h2>Our school trip</h2>
    <h2>My best friend</h2>
  24. 24.🏷️ What does a closing tag have that an opening tag does not? (a) a dot . (b) a hash # (c) a slash / (d) a dollar $
  25. 25.True or false: <title> goes in the body. (a) False (b) True
  26. 26.Which of these is true of a code editor? (a) opens web pages for us (b) stores a website’s files (c) shows pages from the web (d) colours code to help us
  27. 27.Which of these is true of a code editor? (a) saves our .html files (b) hosts websites online (c) has an address bar (d) turns HTML into a page
  28. 28.📝 On how many lines does the browser show this paragraph?
    <p>Stars shine<br>Roses are red<br>Kites fly high</p>
  29. 29.True or false: in <img>, src names the picture file. (a) True (b) False
  30. 30.True or false: HTML on its own cannot run a game loop. (a) False (b) True
  31. 31.🖼️ Which tag puts a picture on a page? (a) <pic> (b) <a> (c) <p> (d) <img>
  32. 32.🖼️ Which picture file does the browser load?
    <img src="kite.png" alt="A red kite" width="100">
    (a) A red kite (b) map.png (c) cake.jpg (d) kite.png
  33. 33.📋 What number does the browser show next to “Litchi”?
    <ol>
      <li>Banana</li>
      <li>Litchi</li>
      <li>Mango</li>
      <li>Grapes</li>
    </ol>
  34. 34.💬 How many paragraphs show on the page?
    <p>Hello, world!</p>
    <!-- <p>Cricket is fun.</p> -->
    <p>My pets</p>
    <!-- <p>My best friend</p> -->
  35. 35.🔗 Where does this link open?
    <a href="quiz.html">Take the quiz</a>
    (a) in the same tab (b) in a new tab
  36. 36.🖼️ How many pixels wide is the picture drawn?
    <img src="bus.jpg" alt="Our school bus" width="300">
  37. 37.📄 Where does <a> go: in the head or in the body? (a) in the body (b) in the head
  38. 38.True or false: <title> goes in the head. (a) False (b) True
  39. 39.Which of these is true of a web browser? (a) colours code to help us (b) hosts websites online (c) answers page requests (d) has an address bar
  40. 40.🔠 Which heading shows the BIGGEST text: <h3>, <h2>, <h4> or <h5>? (a) <h5> (b) <h3> (c) <h2> (d) <h4>

Answer key

  1. <ul>
  2. 3
  3. <ul>
  4. 3
  5. 3
  6. <style>
  7. stores a website’s files
  8. Yes
  9. True
  10. <li>
  11. <input>
  12. <h6>
  13. an opening tag
  14. line 2
  15. <ol>
  16. Play games
  17. line 1
  18. <link rel="stylesheet">
  19. <ul>
  20. Class 7 Blog
  21. <h1>
  22. tags
  23. 1
  24. a slash /
  25. False
  26. colours code to help us
  27. saves our .html files
  28. 3
  29. True
  30. True
  31. <img>
  32. kite.png
  33. 2
  34. 2
  35. in the same tab
  36. 300
  37. in the body
  38. True
  39. has an address bar
  40. <h2>

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