← HTML basics test lesson New set →

HTML Worksheet: Practice Test

HTML and CSS lesson 10: HTML basics test · Set 711 · 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.🔍 One closing tag is missing. Which one?
    <u>Fun facts</u>
    <p>I love mangoes.</p>
    <h2>Good morning!
    (a) </p> (b) </u> (c) </em> (d) </h2>
  2. 2.📄 Which part holds everything you see on the page? (a) the head (b) the title (c) the body (d) the doctype
  3. 3.📋 Does this list show bullets or numbers?
    <ol>
      <li>Papaya</li>
      <li>Grapes</li>
      <li>Banana</li>
    </ol>
    (a) numbers (b) bullets
  4. 4.Which of these is true of a code editor? (a) sends pages over the net (b) shows pages from the web (c) shows line numbers (d) hosts websites online
  5. 5.📋 Which list suits a shopping list in any order? (a) <ul> (b) <ol> (c) <br> (d) <hr>
  6. 6.📋 Which list tag lists things in any order? (a) <ol> (b) <ul> (c) <li>
  7. 7.📝 Does <img> have a closing tag, or is it an empty tag? (a) has a closing tag (b) an empty tag
  8. 8.📄 Can HTML on its own make tables? (a) No (b) Yes
  9. 9.🔗 Which attribute holds the address of a link? (a) src (b) alt (c) id (d) href
  10. 10.True or false: HTML on its own can run a game loop. (a) True (b) False
  11. 11.📋 Does this list show bullets or numbers?
    <ol>
      <li>Papaya</li>
      <li>Banana</li>
      <li>Mango</li>
    </ol>
    (a) bullets (b) numbers
  12. 12.🔠 Which heading shows the BIGGEST text: <h1>, <h5>, <h2> or <h4>? (a) <h5> (b) <h4> (c) <h2> (d) <h1>
  13. 13.💬 Which text will NOT show on the page?
    <p>The red kite</p>
    <p>I love mangoes.</p>
    <!-- <p>Our school trip</p> -->
    (a) The red kite (b) Our school trip (c) I love mangoes.
  14. 14.📋 How many items does this list show?
    <ul>
      <li>Jamun</li>
      <li>Banana</li>
      <li>Orange</li>
      <li>Guava</li>
      <li>Mango</li>
      <li>Papaya</li>
    </ul>
  15. 15.📋 Does this list show bullets or numbers?
    <ol>
      <li>Mango</li>
      <li>Litchi</li>
      <li>Papaya</li>
    </ol>
    (a) bullets (b) numbers
  16. 16.💬 How does an HTML comment end? (a) // (b) >> (c) */ (d) -->
  17. 17.🏷️ Which is the closing tag for <small>? (a) </small> (b) <\small> (c) <small> (d) <small/>
  18. 18.🔠 Which heading shows the BIGGEST text: <h6>, <h4>, <h3> or <h5>? (a) <h4> (b) <h5> (c) <h6> (d) <h3>
  19. 19.🔍 Which line is missing its closing tag?
    line 1: <strong>Good morning!
    line 2: <u>My pets</u>
    line 3: <h3>Fun facts</h3>
    (a) line 3 (b) line 2 (c) line 1
  20. 20.📝 How many paragraphs does this code make?
    <p>Our school trip</p>
    <p>Cricket is fun.</p>
    <p>I love mangoes.</p>
    <h2>Cricket is fun.</h2>
    <p>Our school trip</p>
  21. 21.Which of these has a closing tag? (a) <hr> (b) <br> (c) <img> (d) <p>
  22. 22.📋 Which list tag lists steps in order? (a) <li> (b) <ul> (c) <ol>
  23. 23.🔗 Where does this link open?
    <a href="maths.html">Contact us</a>
    (a) in the same tab (b) in a new tab
  24. 24.📝 Does <title> have a closing tag, or is it an empty tag? (a) has a closing tag (b) an empty tag
  25. 25.📛 In <a href="x.html">, what is href? (a) a closing tag (b) a comment (c) an attribute (d) an element name
  26. 26.📄 Where does <ul> go: in the head or in the body? (a) in the head (b) in the body
  27. 27.📝 How many paragraphs does this code make?
    <p>Fun facts</p>
    <p>Good morning!</p>
    <h2>Good morning!</h2>
  28. 28.📄 What does the browser tab show for this page?
    <!DOCTYPE html>
    <html>
    <head>
      <title>Riya’s Recipes</title>
    </head>
    <body>
      <h1>Match report</h1>
      <p>Try this poha.</p>
    </body>
    </html>
    (a) Match report (b) index.html (c) Riya’s Recipes (d) Try this poha.
  29. 29.📋 What number does the browser show next to “Litchi”?
    <ol start="3">
      <li>Banana</li>
      <li>Guava</li>
      <li>Grapes</li>
      <li>Litchi</li>
      <li>Papaya</li>
    </ol>
  30. 30.📝 How many paragraphs does this code make?
    <p>Hello, world!</p>
    <p>I love mangoes.</p>
    <p>I love mangoes.</p>
    <h2>My best friend</h2>
    <p>Cricket is fun.</p>
  31. 31.📋 Which list tag shows 1, 2, 3 numbers? (a) <ul> (b) <ol> (c) <li>
  32. 32.🖼️ Why do we add alt text to an image? (a) to colour it (b) to describe the image (c) to make it bigger (d) to load it faster
  33. 33.Which of these is a closing tag? (a) <body> (b) <title> (c) <p> (d) </title>
  34. 34.🔠 How many headings are in this code?
    <h1>I love mangoes.</h1>
    <h2>Fun facts</h2>
    <h4>Cricket is fun.</h4>
  35. 35.🖼️ The picture cannot load. Which text does the browser show instead?
    <img src="tiger.jpg" alt="A tiger asleep" width="200">
    (a) A red kite (b) A tiger asleep (c) width (d) tiger.jpg
  36. 36.🔠 Which heading shows the BIGGEST text: <h1>, <h6>, <h4> or <h5>? (a) <h5> (b) <h6> (c) <h1> (d) <h4>
  37. 37.True or false: HTML on its own can make bullet lists. (a) True (b) False
  38. 38.📋 Does this list show bullets or numbers?
    <ol>
      <li>Jamun</li>
      <li>Mango</li>
      <li>Litchi</li>
    </ol>
    (a) numbers (b) bullets
  39. 39.True or false: a web browser saves our .html files. (a) True (b) False
  40. 40.🏷️ Is <li> an opening tag or a closing tag? (a) a closing tag (b) an opening tag

Answer key

  1. </h2>
  2. the body
  3. numbers
  4. shows line numbers
  5. <ul>
  6. <ul>
  7. an empty tag
  8. Yes
  9. href
  10. False
  11. numbers
  12. <h1>
  13. Our school trip
  14. 6
  15. numbers
  16. -->
  17. </small>
  18. <h3>
  19. line 1
  20. 4
  21. <p>
  22. <ol>
  23. in the same tab
  24. has a closing tag
  25. an attribute
  26. in the body
  27. 2
  28. Riya’s Recipes
  29. 6
  30. 4
  31. <ol>
  32. to describe the image
  33. </title>
  34. 3
  35. A tiger asleep
  36. <h1>
  37. True
  38. numbers
  39. False
  40. an opening tag

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