← HTML basics test lesson New set →

HTML Worksheet: Practice Test

HTML and CSS lesson 10: HTML basics test · Set 688 · 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 text will NOT show on the page?
    <p>Cricket is fun.</p>
    <!-- <p>The red kite</p> -->
    <p>Fun facts</p>
    (a) The red kite (b) Fun facts (c) Cricket is fun.
  2. 2.Which of these has a closing tag? (a) <img> (b) <hr> (c) <p> (d) <br>
  3. 3.🖼️ How many pixels wide is the picture drawn?
    <img src="fort.jpg" alt="An old fort" width="300">
  4. 4.Which of these is a closing tag? (a) <h1> (b) </title> (c) <p> (d) <title>
  5. 5.🖼️ The picture cannot load. Which text does the browser show instead?
    <img src="fort.jpg" alt="An old fort" width="300">
    (a) width (b) fort.jpg (c) An old fort (d) A tiger asleep
  6. 6.🔍 Which is the odd one out? (a) turns HTML into a page (b) has an address bar (c) opens web pages for us (d) hosts websites online
  7. 7.📝 How many paragraphs does this code make?
    <p>Fun facts</p>
    <p>Rain today</p>
    <p>I love mangoes.</p>
  8. 8.📋 Which tag goes around each item of a list? (a) <ol> (b) <ul> (c) <p> (d) <li>
  9. 9.📝 On how many lines does the browser show this paragraph?
    <p>Stars shine<br>Roses are red<br>Kites fly high<br>Rivers flow</p>
  10. 10.📝 On how many lines does the browser show this paragraph?
    <p>Roses are red<br>Birds sing<br>Kites fly high<br>Sky is blue<br>Rivers flow</p>
  11. 11.🔍 Which line is missing its closing tag?
    line 1: <h2>Fun facts</h2>
    line 2: <i>Cricket is fun.</i>
    line 3: <strong>I love mangoes.
    (a) line 1 (b) line 2 (c) line 3
  12. 12.📝 On how many lines does the browser show this paragraph?
    <p>Kites fly high<br>Rivers flow</p>
  13. 13.💬 How does an HTML comment end? (a) >> (b) */ (c) // (d) -->
  14. 14.🔗 Which words do you click on?
    <a href="games.html">About us</a>
    (a) Contact us (b) href (c) About us (d) games.html
  15. 15.Which of these is true of a web browser? (a) saves our .html files (b) shows line numbers (c) turns HTML into a page (d) answers page requests
  16. 16.💬 How many paragraphs show on the page?
    <p>Our school trip</p>
    <!-- <p>My best friend</p> -->
    <!-- <p>Hello, world!</p> -->
    <!-- <p>I love mangoes.</p> -->
    <p>Good morning!</p>
  17. 17.True or false: <meta charset="utf-8"> goes in the head. (a) False (b) True
  18. 18.🔠 Which heading shows the SMALLEST text: <h6>, <h4>, <h1> or <h3>? (a) <h4> (b) <h6> (c) <h1> (d) <h3>
  19. 19.📋 Does this list show bullets or numbers?
    <ul>
      <li>Orange</li>
      <li>Litchi</li>
      <li>Jamun</li>
    </ul>
    (a) bullets (b) numbers
  20. 20.📄 Where does the text of <title> appear? (a) nowhere (b) on the browser tab (c) at the bottom (d) in a big heading
  21. 21.💬 How many paragraphs show on the page?
    <!-- <p>Rain today</p> -->
    <p>Good morning!</p>
    <p>The red kite</p>
  22. 22.💬 Which text will NOT show on the page?
    <!-- <p>Rain today</p> -->
    <p>I love mangoes.</p>
    <p>My pets</p>
    <p>Our school trip</p>
    (a) My pets (b) I love mangoes. (c) Our school trip (d) Rain today
  23. 23.🖼️ How many pixels wide is the picture drawn?
    <img src="bus.jpg" alt="Our school bus" width="250">
  24. 24.🔠 Which heading shows the SMALLEST text: <h1>, <h4>, <h5> or <h2>? (a) <h4> (b) <h1> (c) <h5> (d) <h2>
  25. 25.🔠 Which tag is the least important heading? (a) <h3> (b) <h6> (c) <p> (d) <h1>
  26. 26.🔠 Which tag is used for the main title on a page? (a) <br> (b) <h6> (c) <p> (d) <h1>
  27. 27.🔗 Which words do you click on?
    <a href="art.html">Art corner</a>
    (a) School news (b) art.html (c) Art corner (d) href
  28. 28.📋 What number does the browser show next to “Orange”?
    <ol start="6">
      <li>Jamun</li>
      <li>Mango</li>
      <li>Guava</li>
      <li>Orange</li>
      <li>Papaya</li>
      <li>Litchi</li>
    </ol>
  29. 29.🔠 How many heading levels does HTML have? (a) 3 (b) 10 (c) 4 (d) 6
  30. 30.True or false: <a> goes in the body. (a) False (b) True
  31. 31.📋 What number does the browser show next to “Guava”?
    <ol>
      <li>Banana</li>
      <li>Orange</li>
      <li>Grapes</li>
      <li>Guava</li>
      <li>Mango</li>
    </ol>
  32. 32.📄 Where does <img> go: in the head or in the body? (a) in the head (b) in the body
  33. 33.📋 How many items does this list show?
    <ul>
      <li>Mango</li>
      <li>Orange</li>
    </ul>
  34. 34.True or false: <p> is an empty tag. (a) False (b) True
  35. 35.📄 Where does <h1> go: in the head or in the body? (a) in the head (b) in the body
  36. 36.🏷️ Which is the closing tag for <p>? (a) <p/> (b) <p> (c) <\p> (d) </p>
  37. 37.📄 Where does <style> go: in the head or in the body? (a) in the body (b) in the head
  38. 38.🔍 Which line is missing its closing tag?
    line 1: <h2>Our school trip</h2>
    line 2: <b>Hello, world!</b>
    line 3: <i>My best friend
    (a) line 2 (b) line 3 (c) line 1
  39. 39.🔍 Which line is missing its closing tag?
    line 1: <small>Hello, world!</small>
    line 2: <h1>My pets
    line 3: <h3>I love mangoes.</h3>
    (a) line 1 (b) line 3 (c) line 2
  40. 40.📄 What does the browser tab show for this page?
    <!DOCTYPE html>
    <html>
    <head>
      <title>Cricket Club</title>
    </head>
    <body>
      <h1>Easy snacks</h1>
      <p>Here is my best one.</p>
    </body>
    </html>
    (a) Cricket Club (b) Easy snacks (c) Here is my best one. (d) index.html

Answer key

  1. The red kite
  2. <p>
  3. 300
  4. </title>
  5. An old fort
  6. hosts websites online
  7. 3
  8. <li>
  9. 4
  10. 5
  11. line 3
  12. 2
  13. -->
  14. About us
  15. turns HTML into a page
  16. 2
  17. True
  18. <h6>
  19. bullets
  20. on the browser tab
  21. 2
  22. Rain today
  23. 250
  24. <h5>
  25. <h6>
  26. <h1>
  27. Art corner
  28. 9
  29. 6
  30. True
  31. 4
  32. in the body
  33. 2
  34. False
  35. in the body
  36. </p>
  37. in the head
  38. line 3
  39. line 2
  40. Cricket Club

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