← HTML basics test lesson New set →

HTML Worksheet: Practice Test

HTML and CSS lesson 10: HTML basics test · Set 72 · 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 picture file does the browser load?
    <img src="fort.jpg" alt="An old fort" width="100">
    (a) tiger.jpg (b) fort.jpg (c) kite.png (d) An old fort
  2. 2.🔠 How many heading levels does HTML have? (a) 3 (b) 4 (c) 10 (d) 6
  3. 3.Which of these is a closing tag? (a) </body> (b) <title> (c) <body> (d) <p>
  4. 4.True or false: <ol> shows bullet points. (a) True (b) False
  5. 5.📄 Where does <h1> go: in the head or in the body? (a) in the body (b) in the head
  6. 6.💬 Which text will NOT show on the page?
    <p>Fun facts</p>
    <p>Hello, world!</p>
    <!-- <p>Cricket is fun.</p> -->
    <p>My best friend</p>
    (a) Fun facts (b) Cricket is fun. (c) My best friend (d) Hello, world!
  7. 7.🖼️ Which tag puts a picture on a page? (a) <p> (b) <a> (c) <pic> (d) <img>
  8. 8.🖼️ How many pixels wide is the picture drawn?
    <img src="bus.jpg" alt="Our school bus" width="300">
  9. 9.🔗 Which words do you click on?
    <a href="news.html">Take the quiz</a>
    (a) news.html (b) href (c) Take the quiz (d) Play games
  10. 10.True or false: HTML on its own can run a game loop. (a) True (b) False
  11. 11.True or false: <style> goes in the body. (a) False (b) True
  12. 12.🔠 Which tag is the least important heading? (a) <h1> (b) <h3> (c) <h6> (d) <p>
  13. 13.📝 What does <p> make? (a) a table (b) a picture (c) a paragraph (d) a link
  14. 14.💬 Which text will NOT show on the page?
    <p>I love mangoes.</p>
    <p>My best friend</p>
    <p>Good morning!</p>
    <!-- <p>Fun facts</p> -->
    (a) Fun facts (b) I love mangoes. (c) Good morning! (d) My best friend
  15. 15.💬 Which text will NOT show on the page?
    <p>Our school trip</p>
    <p>My pets</p>
    <!-- <p>Cricket is fun.</p> -->
    <p>I love mangoes.</p>
    (a) Our school trip (b) My pets (c) I love mangoes. (d) Cricket is fun.
  16. 16.True or false: <table> goes in the body. (a) False (b) True
  17. 17.Which of these is true of a web browser? (a) colours code to help us (b) answers page requests (c) opens web pages for us (d) is where we type code
  18. 18.🔗 Which address opens when you click this link?
    <a href="about.html">Maths fun</a>
    (a) about.html (b) contact.html (c) Maths fun (d) https://example.com
  19. 19.📄 Can HTML on its own pick a random number? (a) No (b) Yes
  20. 20.🔡 Are HTML tag names usually written in small letters? (a) No (b) Yes
  21. 21.📝 How many paragraphs does this code make?
    <p>Cricket is fun.</p>
    <h2>My pets</h2>
    <p>Fun facts</p>
    <h2>Hello, world!</h2>
    <p>Fun facts</p>
  22. 22.🔠 How many headings are in this code?
    <h1>My best friend</h1>
    <p>My pets</p>
    <h2>Good morning!</h2>
    <h3>The red kite</h3>
    <p>I love mangoes.</p>
  23. 23.Which of these is true of a web server? (a) stores a website’s files (b) has an address bar (c) opens web pages for us (d) colours code to help us
  24. 24.💬 How many paragraphs show on the page?
    <p>Our school trip</p>
    <!-- <p>My pets</p> -->
    <p>My best friend</p>
  25. 25.Which of these is an opening tag? (a) <h1> (b) </b> (c) </h1> (d) </title>
  26. 26.📋 Which tag goes around each item of a list? (a) <li> (b) <ol> (c) <p> (d) <ul>
  27. 27.True or false: HTML on its own cannot run a game loop. (a) False (b) True
  28. 28.📋 What number does the browser show next to “Papaya”?
    <ol>
      <li>Mango</li>
      <li>Papaya</li>
      <li>Guava</li>
      <li>Litchi</li>
      <li>Banana</li>
      <li>Orange</li>
    </ol>
  29. 29.📄 Where does the text of <title> appear? (a) at the bottom (b) in a big heading (c) on the browser tab (d) nowhere
  30. 30.🔗 Where does this link open?
    <a href="about.html">Play games</a>
    (a) in a new tab (b) in the same tab
  31. 31.📋 Which list tag lists steps in order? (a) <ul> (b) <li> (c) <ol>
  32. 32.True or false: a web browser answers page requests. (a) False (b) True
  33. 33.True or false: a code editor shows pages from the web. (a) False (b) True
  34. 34.📋 Does this list show bullets or numbers?
    <ul>
      <li>Orange</li>
      <li>Guava</li>
      <li>Banana</li>
    </ul>
    (a) bullets (b) numbers
  35. 35.🔍 One closing tag is missing. Which one?
    <h3>Fun facts</h3>
    <h2>Rain today</h2>
    <u>Cricket is fun.
    (a) </h3> (b) </small> (c) </u> (d) </h2>
  36. 36.True or false: in <img>, alt is read by screen readers. (a) True (b) False
  37. 37.Which of these goes in the body? (a) <meta charset="utf-8"> (b) <title> (c) <table> (d) <style>
  38. 38.True or false: <li> is an empty tag. (a) True (b) False
  39. 39.📄 Can HTML on its own add up two numbers? (a) Yes (b) No
  40. 40.🏷️ Which is the closing tag for <p>? (a) <p/> (b) <p> (c) <\p> (d) </p>

Answer key

  1. fort.jpg
  2. 6
  3. </body>
  4. False
  5. in the body
  6. Cricket is fun.
  7. <img>
  8. 300
  9. Take the quiz
  10. False
  11. False
  12. <h6>
  13. a paragraph
  14. Fun facts
  15. Cricket is fun.
  16. True
  17. opens web pages for us
  18. about.html
  19. No
  20. Yes
  21. 3
  22. 3
  23. stores a website’s files
  24. 2
  25. <h1>
  26. <li>
  27. True
  28. 2
  29. on the browser tab
  30. in the same tab
  31. <ol>
  32. False
  33. False
  34. bullets
  35. </u>
  36. True
  37. <table>
  38. False
  39. No
  40. </p>

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