← HTML basics test lesson New set →

HTML Worksheet: Practice Test

HTML and CSS lesson 10: HTML basics test · Set 68 · 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 of these is an opening tag? (a) <h1> (b) </body> (c) </b> (d) </title>
  2. 2.📋 How many items does this list show?
    <ul>
      <li>Jamun</li>
      <li>Orange</li>
      <li>Litchi</li>
      <li>Banana</li>
      <li>Grapes</li>
    </ul>
  3. 3.💬 How does an HTML comment start? (a) /* (b) // (c) <!-- (d) #
  4. 4.🖼️ Which picture file does the browser load?
    <img src="map.png" alt="Map of India" width="50">
    (a) Map of India (b) cake.jpg (c) dog.jpg (d) map.png
  5. 5.🏷️ Is <li> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
  6. 6.🔢 In a basic web page file, which comes first: “<head>” or “<body>”? (a) <body> (b) <head>
  7. 7.📄 Where does <p> go: in the head or in the body? (a) in the body (b) in the head
  8. 8.🔠 Which heading shows the SMALLEST text: <h1>, <h3>, <h4> or <h5>? (a) <h3> (b) <h4> (c) <h1> (d) <h5>
  9. 9.🔠 How many <h1> headings should a page usually have? (a) 3 (b) 6 (c) 10 (d) 1
  10. 10.🏷️ Is </title> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
  11. 11.🔢 In a basic web page file, which comes first: “</head>” or “</body>”? (a) </head> (b) </body>
  12. 12.📋 What number does the browser show next to “Litchi”?
    <ol start="3">
      <li>Guava</li>
      <li>Mango</li>
      <li>Litchi</li>
    </ol>
  13. 13.📋 Which list shows the steps of a recipe best? (a) <hr> (b) <ol> (c) <br> (d) <ul>
  14. 14.💬 How many paragraphs show on the page?
    <!-- <p>My best friend</p> -->
    <p>Good morning!</p>
    <p>I love mangoes.</p>
    <p>The red kite</p>
    <p>Fun facts</p>
  15. 15.📝 How many paragraphs does this code make?
    <p>Fun facts</p>
    <p>Rain today</p>
    <p>Rain today</p>
  16. 16.True or false: <img> has a closing tag. (a) True (b) False
  17. 17.🔍 One closing tag is missing. Which one?
    <h2>Cricket is fun.
    <h1>My pets</h1>
    <strong>Good morning!</strong>
    (a) </h1> (b) </h2> (c) </i> (d) </strong>
  18. 18.Which of these is true of a web browser? (a) sends pages over the net (b) shows line numbers (c) stores a website’s files (d) opens web pages for us
  19. 19.📄 What is the big heading shown on this page?
    <!DOCTYPE html>
    <html>
    <head>
      <title>My Hobbies</title>
    </head>
    <body>
      <h1>Welcome!</h1>
      <p>I like to read.</p>
    </body>
    </html>
    (a) My Hobbies (b) body (c) Welcome! (d) I like to read.
  20. 20.🧩 An opening tag + content + a closing tag together make an ___. (a) attribute (b) element (c) editor (d) address
  21. 21.🖼️ Which tag puts a picture on a page? (a) <img> (b) <a> (c) <pic> (d) <p>
  22. 22.📄 Where does <title> go: in the head or in the body? (a) in the head (b) in the body
  23. 23.💬 Which text will NOT show on the page?
    <p>My best friend</p>
    <p>My pets</p>
    <!-- <p>Rain today</p> -->
    (a) My best friend (b) My pets (c) Rain today
  24. 24.📝 How many paragraphs does this code make?
    <p>My pets</p>
    <p>Hello, world!</p>
    <h2>My pets</h2>
    <h2>Good morning!</h2>
    <h2>Rain today</h2>
    <p>My best friend</p>
  25. 25.📄 Can HTML on its own add pictures to a page? (a) Yes (b) No
  26. 26.🔠 How many headings are in this code?
    <h1>Fun facts</h1>
    <h2>Cricket is fun.</h2>
    <p>Good morning!</p>
    <h3>The red kite</h3>
  27. 27.🔠 Which heading shows the BIGGEST text: <h1>, <h2>, <h5> or <h4>? (a) <h1> (b) <h4> (c) <h5> (d) <h2>
  28. 28.📋 Which list tag goes inside ul or ol? (a) <ol> (b) <li> (c) <ul>
  29. 29.🔠 Which tag is used for the main title on a page? (a) <br> (b) <h6> (c) <h1> (d) <p>
  30. 30.Which of these goes in the body? (a) <link rel="stylesheet"> (b) <title> (c) <img> (d) <meta charset="utf-8">
  31. 31.🏷️ Is </li> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
  32. 32.🔍 Which line is missing its closing tag?
    line 1: <h3>Our school trip</h3>
    line 2: <p>I love mangoes.
    line 3: <small>Fun facts</small>
    (a) line 3 (b) line 1 (c) line 2
  33. 33.📋 Which list tag shows 1, 2, 3 numbers? (a) <ol> (b) <li> (c) <ul>
  34. 34.📝 What does <p> make? (a) a table (b) a link (c) a paragraph (d) a picture
  35. 35.📋 Which list tag shows bullet points? (a) <ol> (b) <ul> (c) <li>
  36. 36.🔗 Which tag makes a clickable link? (a) <img> (b) <p> (c) <link> (d) <a>
  37. 37.🏷️ Is <body> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
  38. 38.Which of these goes in the head? (a) <h1> (b) <img> (c) <title> (d) <table>
  39. 39.Which of these is an opening tag? (a) </body> (b) </b> (c) </li> (d) <body>
  40. 40.📋 How many items does this list show?
    <ul>
      <li>Mango</li>
      <li>Guava</li>
      <li>Grapes</li>
    </ul>

Answer key

  1. <h1>
  2. 5
  3. <!--
  4. map.png
  5. an opening tag
  6. <head>
  7. in the body
  8. <h5>
  9. 1
  10. a closing tag
  11. </head>
  12. 5
  13. <ol>
  14. 4
  15. 3
  16. False
  17. </h2>
  18. opens web pages for us
  19. Welcome!
  20. element
  21. <img>
  22. in the head
  23. Rain today
  24. 3
  25. Yes
  26. 3
  27. <h1>
  28. <li>
  29. <h1>
  30. <img>
  31. a closing tag
  32. line 2
  33. <ol>
  34. a paragraph
  35. <ul>
  36. <a>
  37. an opening tag
  38. <title>
  39. <body>
  40. 3

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