← HTML basics test lesson New set →

HTML Worksheet: Practice Test

HTML and CSS lesson 10: HTML basics test · Set 346 · 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 heading shows the SMALLEST text: <h3>, <h2>, <h4> or <h1>? (a) <h4> (b) <h1> (c) <h3> (d) <h2>
  2. 2.True or false: HTML on its own cannot show paragraphs. (a) False (b) True
  3. 3.🏷️ Is </body> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
  4. 4.🖼️ The picture cannot load. Which text does the browser show instead?
    <img src="bus.jpg" alt="Our school bus" width="100">
    (a) Our school bus (b) width (c) An old fort (d) bus.jpg
  5. 5.True or false: <p> goes in the body. (a) False (b) True
  6. 6.🏷️ Every HTML tag starts with which sign? (a) { (b) ( (c) < (d) [
  7. 7.🏷️ What does a closing tag have that an opening tag does not? (a) a hash # (b) a dot . (c) a dollar $ (d) a slash /
  8. 8.Which of these is a closing tag? (a) <li> (b) <h1> (c) </h1> (d) <body>
  9. 9.True or false: HTML on its own cannot run a game loop. (a) False (b) True
  10. 10.🖼️ Which tag puts a picture on a page? (a) <p> (b) <img> (c) <a> (d) <pic>
  11. 11.🔍 Which is the odd one out? (a) hosts websites online (b) turns HTML into a page (c) answers page requests (d) stores a website’s files
  12. 12.🔠 How many headings are in this code?
    <h1>Cricket is fun.</h1>
    <p>Rain today</p>
    <p>Cricket is fun.</p>
  13. 13.🔠 Which tag is the least important heading? (a) <h6> (b) <p> (c) <h1> (d) <h3>
  14. 14.📄 What is the big heading shown on this page?
    <!DOCTYPE html>
    <html>
    <head>
      <title>Art Gallery</title>
    </head>
    <body>
      <h1>All about me</h1>
      <p>Try this poha.</p>
    </body>
    </html>
    (a) body (b) Art Gallery (c) All about me (d) Try this poha.
  15. 15.🔠 Which tag is used for the main title on a page? (a) <h6> (b) <p> (c) <br> (d) <h1>
  16. 16.📝 What does <br> do? (a) adds a picture (b) makes a list (c) makes text bold (d) starts a new line
  17. 17.Which of these is a closing tag? (a) <title> (b) </p> (c) <h1> (d) <body>
  18. 18.📄 Can HTML on its own make bullet lists? (a) No (b) Yes
  19. 19.📄 Where does the text of <title> appear? (a) at the bottom (b) nowhere (c) in a big heading (d) on the browser tab
  20. 20.🔗 Which words do you click on?
    <a href="https://example.com">Art corner</a>
    (a) href (b) https://example.com (c) School news (d) Art corner
  21. 21.🔍 Which line is missing its closing tag?
    line 1: <em>My pets</em>
    line 2: <p>Hello, world!</p>
    line 3: <h3>I love mangoes.
    (a) line 3 (b) line 2 (c) line 1
  22. 22.🔗 Which address opens when you click this link?
    <a href="https://example.com">Play games</a>
    (a) art.html (b) maths.html (c) https://example.com (d) Play games
  23. 23.📋 How many items does this list show?
    <ul>
      <li>Jamun</li>
      <li>Grapes</li>
      <li>Litchi</li>
      <li>Mango</li>
    </ul>
  24. 24.📄 Where does <p> go: in the head or in the body? (a) in the body (b) in the head
  25. 25.🔍 One closing tag is missing. Which one?
    <p>Good morning!
    <i>The red kite</i>
    <strong>I love mangoes.</strong>
    (a) </h2> (b) </strong> (c) </i> (d) </p>
  26. 26.🔍 One closing tag is missing. Which one?
    <h1>Fun facts</h1>
    <em>I love mangoes.</em>
    <h3>Cricket is fun.
    (a) </p> (b) </h1> (c) </h3> (d) </em>
  27. 27.🔠 How many <h1> headings should a page usually have? (a) 3 (b) 10 (c) 1 (d) 6
  28. 28.🔗 Which tag makes a clickable link? (a) <p> (b) <img> (c) <a> (d) <link>
  29. 29.🔠 Which heading shows the SMALLEST text: <h2>, <h1>, <h4> or <h3>? (a) <h3> (b) <h2> (c) <h4> (d) <h1>
  30. 30.🖼️ Which attribute of <img> names the picture file? (a) width (b) height (c) alt (d) src
  31. 31.🔗 Where does this link open?
    <a href="games.html">Art corner</a>
    (a) in a new tab (b) in the same tab
  32. 32.🔠 Which heading shows the SMALLEST text: <h4>, <h3>, <h6> or <h2>? (a) <h4> (b) <h3> (c) <h2> (d) <h6>
  33. 33.🔠 How many headings are in this code?
    <h1>Good morning!</h1>
    <h2>My pets</h2>
    <p>My best friend</p>
    <p>Hello, world!</p>
  34. 34.💬 How many paragraphs show on the page?
    <!-- <p>My best friend</p> -->
    <!-- <p>Rain today</p> -->
    <p>My pets</p>
    <p>Our school trip</p>
  35. 35.📋 Which list shows the steps of a recipe best? (a) <hr> (b) <ul> (c) <ol> (d) <br>
  36. 36.📄 What does the browser tab show for this page?
    <!DOCTYPE html>
    <html>
    <head>
      <title>Space Facts</title>
    </head>
    <body>
      <h1>Match report</h1>
      <p>Thanks for visiting.</p>
    </body>
    </html>
    (a) Thanks for visiting. (b) Match report (c) Space Facts (d) index.html
  37. 37.💬 How many paragraphs show on the page?
    <p>My pets</p>
    <p>Cricket is fun.</p>
    <!-- <p>Good morning!</p> -->
  38. 38.🖼️ The picture cannot load. Which text does the browser show instead?
    <img src="map.png" alt="Map of India" width="150">
    (a) Birthday cake (b) map.png (c) width (d) Map of India
  39. 39.🔠 How many heading levels does HTML have? (a) 3 (b) 6 (c) 10 (d) 4
  40. 40.💬 How does an HTML comment start? (a) /* (b) <!-- (c) // (d) #

Answer key

  1. <h4>
  2. False
  3. a closing tag
  4. Our school bus
  5. True
  6. <
  7. a slash /
  8. </h1>
  9. True
  10. <img>
  11. turns HTML into a page
  12. 1
  13. <h6>
  14. All about me
  15. <h1>
  16. starts a new line
  17. </p>
  18. Yes
  19. on the browser tab
  20. Art corner
  21. line 3
  22. https://example.com
  23. 4
  24. in the body
  25. </p>
  26. </h3>
  27. 1
  28. <a>
  29. <h4>
  30. src
  31. in the same tab
  32. <h6>
  33. 2
  34. 2
  35. <ol>
  36. Space Facts
  37. 2
  38. Map of India
  39. 6
  40. <!--

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