← HTML basics test lesson New set →

HTML Worksheet: Practice Test

HTML and CSS lesson 10: HTML basics test · Set 815 · 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?
    <small>My pets
    <h1>Hello, world!</h1>
    <i>Fun facts</i>
    (a) </h1> (b) </u> (c) </i> (d) </small>
  2. 2.🔍 Which line is missing its closing tag?
    line 1: <p>My best friend</p>
    line 2: <small>My pets</small>
    line 3: <em>Good morning!
    (a) line 2 (b) line 3 (c) line 1
  3. 3.🔢 In a basic web page file, which comes FIRST? (a) <body> (b) <head> (c) </head> (d) <!DOCTYPE html>
  4. 4.🏷️ Is </li> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
  5. 5.Which of these is an opening tag? (a) </p> (b) </body> (c) <li> (d) </b>
  6. 6.🔗 Which address opens when you click this link?
    <a href="news.html">Play games</a>
    (a) news.html (b) Play games (c) games.html (d) quiz.html
  7. 7.📄 Where does the text of <title> appear? (a) at the bottom (b) on the browser tab (c) nowhere (d) in a big heading
  8. 8.Which of these is true of a web server? (a) hosts websites online (b) opens web pages for us (c) shows pages from the web (d) turns HTML into a page
  9. 9.🏷️ Which is the closing tag for <i>? (a) </i> (b) <i> (c) <i/> (d) <\i>
  10. 10.🖼️ How many pixels wide is the picture drawn?
    <img src="kite.png" alt="A red kite" width="250">
  11. 11.📄 Which part holds everything you see on the page? (a) the doctype (b) the title (c) the body (d) the head
  12. 12.🔍 Which line is missing its closing tag?
    line 1: <h1>Fun facts</h1>
    line 2: <strong>Good morning!
    line 3: <p>The red kite</p>
    (a) line 1 (b) line 2 (c) line 3
  13. 13.🏷️ Which is the closing tag for <em>? (a) <\em> (b) <em/> (c) <em> (d) </em>
  14. 14.💬 Which text will NOT show on the page?
    <p>The red kite</p>
    <p>Hello, world!</p>
    <!-- <p>My best friend</p> -->
    (a) My best friend (b) The red kite (c) Hello, world!
  15. 15.📝 Does <b> have a closing tag, or is it an empty tag? (a) an empty tag (b) has a closing tag
  16. 16.📝 What does <hr> draw? (a) a link (b) a line across the page (c) a table (d) a picture
  17. 17.True or false: a web server hosts websites online. (a) True (b) False
  18. 18.💬 How many paragraphs show on the page?
    <p>Fun facts</p>
    <!-- <p>My pets</p> -->
    <p>Cricket is fun.</p>
    <!-- <p>Hello, world!</p> -->
  19. 19.📋 Which list suits a shopping list in any order? (a) <br> (b) <ul> (c) <hr> (d) <ol>
  20. 20.🔠 Which tag is used for the main title on a page? (a) <p> (b) <br> (c) <h6> (d) <h1>
  21. 21.📋 What number does the browser show next to “Banana”?
    <ol start="7">
      <li>Litchi</li>
      <li>Orange</li>
      <li>Jamun</li>
      <li>Banana</li>
    </ol>
  22. 22.💬 Which text will NOT show on the page?
    <p>My best friend</p>
    <p>Fun facts</p>
    <!-- <p>My pets</p> -->
    (a) Fun facts (b) My best friend (c) My pets
  23. 23.🌐 Which one shows pages from the web? (a) a code editor (b) a web server (c) a web browser
  24. 24.True or false: <meta charset="utf-8"> goes in the body. (a) True (b) False
  25. 25.💬 How many paragraphs show on the page?
    <p>I love mangoes.</p>
    <p>My pets</p>
    <p>Good morning!</p>
    <!-- <p>Our school trip</p> -->
    <p>The red kite</p>
  26. 26.True or false: in <img>, height describes the picture. (a) True (b) False
  27. 27.💬 How many paragraphs show on the page?
    <p>I love mangoes.</p>
    <p>The red kite</p>
    <!-- <p>Fun facts</p> -->
  28. 28.🔗 Where does this link open?
    <a href="maths.html" target="_blank">Play games</a>
    (a) in a new tab (b) in the same tab
  29. 29.📋 What number does the browser show next to “Orange”?
    <ol start="4">
      <li>Papaya</li>
      <li>Mango</li>
      <li>Orange</li>
      <li>Jamun</li>
    </ol>
  30. 30.🔍 Which line is missing its closing tag?
    line 1: <strong>Hello, world!
    line 2: <small>Rain today</small>
    line 3: <h3>Our school trip</h3>
    (a) line 2 (b) line 1 (c) line 3
  31. 31.📄 What does the browser tab show for this page?
    <!DOCTYPE html>
    <html>
    <head>
      <title>Cricket Club</title>
    </head>
    <body>
      <h1>My drawings</h1>
      <p>Mars is red.</p>
    </body>
    </html>
    (a) index.html (b) My drawings (c) Cricket Club (d) Mars is red.
  32. 32.🔍 One closing tag is missing. Which one?
    <h2>My best friend
    <p>Fun facts</p>
    <u>The red kite</u>
    (a) </p> (b) </h3> (c) </u> (d) </h2>
  33. 33.🔗 Which words do you click on?
    <a href="art.html">Play games</a>
    (a) art.html (b) About us (c) Play games (d) href
  34. 34.📄 Can HTML on its own add pictures to a page? (a) No (b) Yes
  35. 35.📝 Does <br> have a closing tag, or is it an empty tag? (a) has a closing tag (b) an empty tag
  36. 36.📋 How many items does this list show?
    <ol>
      <li>Jamun</li>
      <li>Grapes</li>
      <li>Papaya</li>
      <li>Guava</li>
      <li>Mango</li>
    </ol>
  37. 37.🔠 Which heading shows the BIGGEST text: <h1>, <h4>, <h2> or <h3>? (a) <h2> (b) <h3> (c) <h1> (d) <h4>
  38. 38.💬 Which text will NOT show on the page?
    <p>My pets</p>
    <p>Fun facts</p>
    <!-- <p>Our school trip</p> -->
    <p>I love mangoes.</p>
    (a) Fun facts (b) I love mangoes. (c) My pets (d) Our school trip
  39. 39.🔍 Which line is missing its closing tag?
    line 1: <h3>The red kite
    line 2: <i>Cricket is fun.</i>
    line 3: <p>Fun facts</p>
    (a) line 3 (b) line 1 (c) line 2
  40. 40.🏷️ Which is the closing tag for <p>? (a) </p> (b) <\p> (c) <p/> (d) <p>

Answer key

  1. </small>
  2. line 3
  3. <!DOCTYPE html>
  4. a closing tag
  5. <li>
  6. news.html
  7. on the browser tab
  8. hosts websites online
  9. </i>
  10. 250
  11. the body
  12. line 2
  13. </em>
  14. My best friend
  15. has a closing tag
  16. a line across the page
  17. True
  18. 2
  19. <ul>
  20. <h1>
  21. 10
  22. My pets
  23. a web browser
  24. False
  25. 4
  26. False
  27. 2
  28. in a new tab
  29. 6
  30. line 1
  31. Cricket Club
  32. </h2>
  33. Play games
  34. Yes
  35. an empty tag
  36. 5
  37. <h1>
  38. Our school trip
  39. line 1
  40. </p>

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