← HTML basics test lesson New set →

HTML Worksheet: Practice Test

HTML and CSS lesson 10: HTML basics test · Set 315 · 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.📄 Where does <a> go: in the head or in the body? (a) in the head (b) in the body
  2. 2.🔠 Which heading shows the BIGGEST text: <h4>, <h5>, <h1> or <h2>? (a) <h5> (b) <h1> (c) <h4> (d) <h2>
  3. 3.📄 Where does <ul> go: in the head or in the body? (a) in the body (b) in the head
  4. 4.💬 Which text will NOT show on the page?
    <!-- <p>Fun facts</p> -->
    <p>My pets</p>
    <p>My best friend</p>
    (a) My best friend (b) My pets (c) Fun facts
  5. 5.📋 Which list suits a shopping list in any order? (a) <br> (b) <ol> (c) <hr> (d) <ul>
  6. 6.🔠 How many headings are in this code?
    <h1>The red kite</h1>
    <h3>Good morning!</h3>
    <h2>Good morning!</h2>
    <h3>Cricket is fun.</h3>
  7. 7.🔠 How many headings are in this code?
    <h1>Fun facts</h1>
    <h2>I love mangoes.</h2>
    <h3>I love mangoes.</h3>
  8. 8.🖼️ Which tag puts a picture on a page? (a) <a> (b) <pic> (c) <p> (d) <img>
  9. 9.🔠 Which heading shows the BIGGEST text: <h2>, <h5>, <h3> or <h6>? (a) <h5> (b) <h3> (c) <h6> (d) <h2>
  10. 10.🖼️ Why do we add alt text to an image? (a) to load it faster (b) to describe the image (c) to make it bigger (d) to colour it
  11. 11.📄 Where does <title> go: in the head or in the body? (a) in the body (b) in the head
  12. 12.🔗 Which address opens when you click this link?
    <a href="games.html">Visit the site</a>
    (a) about.html (b) Visit the site (c) games.html (d) contact.html
  13. 13.True or false: <ul> is an empty tag. (a) False (b) True
  14. 14.📝 On how many lines does the browser show this paragraph?
    <p>Roses are red<br>Stars shine<br>Kites fly high<br>Birds sing<br>Rivers flow</p>
  15. 15.📝 What does <br> do? (a) makes text bold (b) starts a new line (c) adds a picture (d) makes a list
  16. 16.True or false: HTML on its own can make bullet lists. (a) False (b) True
  17. 17.🖼️ Which picture file does the browser load?
    <img src="fort.jpg" alt="An old fort" width="350">
    (a) tiger.jpg (b) An old fort (c) kite.png (d) fort.jpg
  18. 18.📋 What number does the browser show next to “Mango”?
    <ol>
      <li>Papaya</li>
      <li>Mango</li>
      <li>Jamun</li>
    </ol>
  19. 19.🔠 Which heading shows the BIGGEST text: <h5>, <h3>, <h4> or <h1>? (a) <h5> (b) <h4> (c) <h1> (d) <h3>
  20. 20.True or false: <ul> shows bullet points. (a) False (b) True
  21. 21.📄 Can HTML on its own make links to pages? (a) No (b) Yes
  22. 22.🔠 Which heading shows the BIGGEST text: <h2>, <h1>, <h3> or <h6>? (a) <h6> (b) <h3> (c) <h2> (d) <h1>
  23. 23.📄 What is the big heading shown on this page?
    <!DOCTYPE html>
    <html>
    <head>
      <title>My Hobbies</title>
    </head>
    <body>
      <h1>All about me</h1>
      <p>I like to read.</p>
    </body>
    </html>
    (a) My Hobbies (b) All about me (c) body (d) I like to read.
  24. 24.True or false: a web server stores a website’s files. (a) False (b) True
  25. 25.True or false: a code editor colours code to help us. (a) False (b) True
  26. 26.🔢 In a basic web page file, which comes first: “<!DOCTYPE html>” or “</html>”? (a) <!DOCTYPE html> (b) </html>
  27. 27.True or false: <link rel="stylesheet"> goes in the head. (a) False (b) True
  28. 28.📝 How many paragraphs does this code make?
    <p>The red kite</p>
    <h2>My pets</h2>
    <p>My best friend</p>
    <p>I love mangoes.</p>
    <p>The red kite</p>
  29. 29.🔗 Which words do you click on?
    <a href="about.html">About us</a>
    (a) Contact us (b) href (c) About us (d) about.html
  30. 30.🔠 Which heading shows the BIGGEST text: <h2>, <h4>, <h6> or <h5>? (a) <h5> (b) <h4> (c) <h6> (d) <h2>
  31. 31.🔍 One closing tag is missing. Which one?
    <h3>The red kite
    <p>I love mangoes.</p>
    <h2>My best friend</h2>
    (a) </p> (b) </i> (c) </h2> (d) </h3>
  32. 32.🏷️ Is <li> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
  33. 33.🔤 In “HTML”, what does the L stand for? (a) Line (b) Language (c) Link (d) Laptop
  34. 34.📝 How many paragraphs does this code make?
    <p>Our school trip</p>
    <p>I love mangoes.</p>
    <h2>My best friend</h2>
  35. 35.🔗 Which address opens when you click this link?
    <a href="games.html">About us</a>
    (a) about.html (b) contact.html (c) games.html (d) About us
  36. 36.🔗 Which words do you click on?
    <a href="contact.html">Visit the site</a>
    (a) Maths fun (b) href (c) Visit the site (d) contact.html
  37. 37.🏷️ What does a closing tag have that an opening tag does not? (a) a dollar $ (b) a dot . (c) a slash / (d) a hash #
  38. 38.🔍 One closing tag is missing. Which one?
    <em>Hello, world!</em>
    <h2>My best friend
    <h1>Good morning!</h1>
    (a) </u> (b) </em> (c) </h2> (d) </h1>
  39. 39.🔗 Which address opens when you click this link?
    <a href="games.html">School news</a>
    (a) contact.html (b) about.html (c) games.html (d) School news
  40. 40.📄 Where does <p> go: in the head or in the body? (a) in the head (b) in the body

Answer key

  1. in the body
  2. <h1>
  3. in the body
  4. Fun facts
  5. <ul>
  6. 4
  7. 3
  8. <img>
  9. <h2>
  10. to describe the image
  11. in the head
  12. games.html
  13. False
  14. 5
  15. starts a new line
  16. True
  17. fort.jpg
  18. 2
  19. <h1>
  20. True
  21. Yes
  22. <h1>
  23. All about me
  24. True
  25. True
  26. <!DOCTYPE html>
  27. True
  28. 4
  29. About us
  30. <h2>
  31. </h3>
  32. an opening tag
  33. Language
  34. 2
  35. games.html
  36. Visit the site
  37. a slash /
  38. </h2>
  39. games.html
  40. in the body

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