← HTML basics test lesson New set →

HTML Worksheet: Practice Test

HTML and CSS lesson 10: HTML basics test · Set 368 · 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>, <h1> or <h6>? (a) <h3> (b) <h2> (c) <h6> (d) <h1>
  2. 2.True or false: <p> has a closing tag. (a) False (b) True
  3. 3.📄 Where does <p> go: in the head or in the body? (a) in the head (b) in the body
  4. 4.💬 Which text will NOT show on the page?
    <p>Good morning!</p>
    <!-- <p>Cricket is fun.</p> -->
    <p>Hello, world!</p>
    (a) Good morning! (b) Hello, world! (c) Cricket is fun.
  5. 5.🔍 Which line is missing its closing tag?
    line 1: <h2>Good morning!
    line 2: <h3>Fun facts</h3>
    line 3: <u>My best friend</u>
    (a) line 3 (b) line 1 (c) line 2
  6. 6.🔠 Which tag is used for the main title on a page? (a) <br> (b) <p> (c) <h1> (d) <h6>
  7. 7.🔍 Which is the odd one out? (a) hosts websites online (b) colours code to help us (c) is where we type code (d) shows line numbers
  8. 8.💬 Which text will NOT show on the page?
    <p>Cricket is fun.</p>
    <p>Rain today</p>
    <!-- <p>My best friend</p> -->
    (a) Rain today (b) Cricket is fun. (c) My best friend
  9. 9.🔠 Which heading shows the BIGGEST text: <h6>, <h1>, <h2> or <h5>? (a) <h2> (b) <h1> (c) <h6> (d) <h5>
  10. 10.📝 Does <h1> have a closing tag, or is it an empty tag? (a) an empty tag (b) has a closing tag
  11. 11.💬 How many paragraphs show on the page?
    <!-- <p>Rain today</p> -->
    <!-- <p>Fun facts</p> -->
    <p>My pets</p>
    <!-- <p>Hello, world!</p> -->
  12. 12.📝 Does <b> have a closing tag, or is it an empty tag? (a) an empty tag (b) has a closing tag
  13. 13.🌐 Which one hosts websites online? (a) a web browser (b) a web server (c) a code editor
  14. 14.🔗 Which address opens when you click this link?
    <a href="art.html">School news</a>
    (a) art.html (b) news.html (c) quiz.html (d) School news
  15. 15.🖼️ Which attribute of <img> shows if the image fails? (a) width (b) src (c) alt (d) height
  16. 16.🔍 Which is the odd one out? (a) is where we type code (b) shows pages from the web (c) has an address bar (d) opens web pages for us
  17. 17.Which of these is a closing tag? (a) <title> (b) </b> (c) <p> (d) <h1>
  18. 18.True or false: <meta charset="utf-8"> goes in the head. (a) False (b) True
  19. 19.🔠 How many headings are in this code?
    <h1>Rain today</h1>
    <p>Rain today</p>
    <p>Good morning!</p>
    <h2>My pets</h2>
    <h2>Rain today</h2>
  20. 20.💬 How many paragraphs show on the page?
    <!-- <p>My pets</p> -->
    <p>Good morning!</p>
    <p>Our school trip</p>
    <!-- <p>My best friend</p> -->
  21. 21.💬 Which text will NOT show on the page?
    <p>Hello, world!</p>
    <!-- <p>I love mangoes.</p> -->
    <p>My pets</p>
    <p>Our school trip</p>
    (a) I love mangoes. (b) My pets (c) Our school trip (d) Hello, world!
  22. 22.📄 Where does the text of <title> appear? (a) at the bottom (b) in a big heading (c) nowhere (d) on the browser tab
  23. 23.True or false: HTML on its own can show paragraphs. (a) False (b) True
  24. 24.💬 How many paragraphs show on the page?
    <!-- <p>Fun facts</p> -->
    <p>My best friend</p>
    <!-- <p>I love mangoes.</p> -->
  25. 25.🔠 How many <h1> headings should a page usually have? (a) 10 (b) 3 (c) 1 (d) 6
  26. 26.📝 On how many lines does the browser show this paragraph?
    <p>Birds sing<br>Stars shine<br>Rivers flow<br>Kites fly high<br>Roses are red</p>
  27. 27.🖼️ Does <img> need a closing tag? (a) Yes (b) No
  28. 28.True or false: HTML on its own cannot make bullet lists. (a) False (b) True
  29. 29.💬 Does the browser show comments on the page? (a) Yes (b) No
  30. 30.📋 Does this list show bullets or numbers?
    <ol>
      <li>Jamun</li>
      <li>Papaya</li>
      <li>Grapes</li>
    </ol>
    (a) bullets (b) numbers
  31. 31.🖼️ Which attribute of <img> is read by screen readers? (a) alt (b) height (c) src (d) width
  32. 32.True or false: HTML on its own can make bullet lists. (a) True (b) False
  33. 33.🏷️ Is <b> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
  34. 34.🔠 Which heading shows the BIGGEST text: <h2>, <h4>, <h3> or <h1>? (a) <h2> (b) <h4> (c) <h3> (d) <h1>
  35. 35.🔗 What does target="_blank" do to a link? (a) opens it in a new tab (b) makes it bold (c) hides the link (d) makes it blank
  36. 36.True or false: a code editor turns HTML into a page. (a) False (b) True
  37. 37.📝 How many paragraphs does this code make?
    <p>My pets</p>
    <p>I love mangoes.</p>
    <h2>Good morning!</h2>
  38. 38.True or false: a web browser hosts websites online. (a) True (b) False
  39. 39.📋 Does this list show bullets or numbers?
    <ol>
      <li>Guava</li>
      <li>Orange</li>
    </ol>
    (a) bullets (b) numbers
  40. 40.🖼️ The picture cannot load. Which text does the browser show instead?
    <img src="kite.png" alt="A red kite" width="400">
    (a) Map of India (b) A red kite (c) kite.png (d) width

Answer key

  1. <h6>
  2. True
  3. in the body
  4. Cricket is fun.
  5. line 1
  6. <h1>
  7. hosts websites online
  8. My best friend
  9. <h1>
  10. has a closing tag
  11. 1
  12. has a closing tag
  13. a web server
  14. art.html
  15. alt
  16. is where we type code
  17. </b>
  18. True
  19. 3
  20. 2
  21. I love mangoes.
  22. on the browser tab
  23. True
  24. 1
  25. 1
  26. 5
  27. No
  28. False
  29. No
  30. numbers
  31. alt
  32. True
  33. an opening tag
  34. <h1>
  35. opens it in a new tab
  36. False
  37. 2
  38. False
  39. numbers
  40. A red kite

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