← HTML basics test lesson New set →

HTML Worksheet: Practice Test

HTML and CSS lesson 10: HTML basics test · Set 67 · 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 has a closing tag? (a) <meta> (b) <img> (c) <h1> (d) <br>
  2. 2.📛 In <a href="x.html">, what is href? (a) an element name (b) an attribute (c) a closing tag (d) a comment
  3. 3.Which of these is a closing tag? (a) <b> (b) <h1> (c) <p> (d) </li>
  4. 4.🔤 In “HTML”, what does the L stand for? (a) Line (b) Laptop (c) Link (d) Language
  5. 5.💬 How many paragraphs show on the page?
    <p>My pets</p>
    <p>My best friend</p>
    <!-- <p>Hello, world!</p> -->
  6. 6.📋 Does this list show bullets or numbers?
    <ul>
      <li>Banana</li>
      <li>Orange</li>
    </ul>
    (a) bullets (b) numbers
  7. 7.📄 Where does the text of <title> appear? (a) in a big heading (b) on the browser tab (c) nowhere (d) at the bottom
  8. 8.Which of these is true of a code editor? (a) answers page requests (b) sends pages over the net (c) is where we type code (d) shows pages from the web
  9. 9.📋 Which tag goes around each item of a list? (a) <ul> (b) <ol> (c) <li> (d) <p>
  10. 10.Which of these is true of a web server? (a) is where we type code (b) opens web pages for us (c) sends pages over the net (d) colours code to help us
  11. 11.🖼️ The picture cannot load. Which text does the browser show instead?
    <img src="bus.jpg" alt="Our school bus" width="400">
    (a) Our school bus (b) An old fort (c) bus.jpg (d) width
  12. 12.🖼️ Which picture file does the browser load?
    <img src="map.png" alt="Map of India" width="50">
    (a) Map of India (b) map.png (c) dog.jpg (d) cake.jpg
  13. 13.📋 Which list suits a shopping list in any order? (a) <ol> (b) <br> (c) <hr> (d) <ul>
  14. 14.📄 What does the browser tab show for this page?
    <!DOCTYPE html>
    <html>
    <head>
      <title>Art Gallery</title>
    </head>
    <body>
      <h1>Planets</h1>
      <p>Here is my best one.</p>
    </body>
    </html>
    (a) Art Gallery (b) Planets (c) index.html (d) Here is my best one.
  15. 15.True or false: <p> is an empty tag. (a) True (b) False
  16. 16.True or false: <p> goes in the head. (a) True (b) False
  17. 17.🔍 One closing tag is missing. Which one?
    <small>Rain today</small>
    <h2>My best friend
    <h1>Fun facts</h1>
    (a) </h2> (b) </b> (c) </h1> (d) </small>
  18. 18.💬 Which text will NOT show on the page?
    <!-- <p>Cricket is fun.</p> -->
    <p>Hello, world!</p>
    <p>Rain today</p>
    <p>Our school trip</p>
    (a) Hello, world! (b) Rain today (c) Cricket is fun. (d) Our school trip
  19. 19.🔗 Which words do you click on?
    <a href="about.html">Play games</a>
    (a) href (b) About us (c) Play games (d) about.html
  20. 20.💬 Can anyone read your comments by viewing the page source? (a) Yes (b) No
  21. 21.Which of these is an opening tag? (a) </p> (b) </title> (c) </li> (d) <body>
  22. 22.📄 What does the browser tab show for this page?
    <!DOCTYPE html>
    <html>
    <head>
      <title>Space Facts</title>
    </head>
    <body>
      <h1>Welcome!</h1>
      <p>I like to read.</p>
    </body>
    </html>
    (a) Welcome! (b) I like to read. (c) index.html (d) Space Facts
  23. 23.📝 On how many lines does the browser show this paragraph?
    <p>Sky is blue<br>Stars shine</p>
  24. 24.True or false: HTML on its own cannot make links to pages. (a) True (b) False
  25. 25.🔍 Which is the odd one out? (a) stores a website’s files (b) opens web pages for us (c) answers page requests (d) hosts websites online
  26. 26.🖼️ Which picture file does the browser load?
    <img src="map.png" alt="Map of India" width="350">
    (a) cake.jpg (b) map.png (c) Map of India (d) dog.jpg
  27. 27.🔗 Which address opens when you click this link?
    <a href="https://example.com">Take the quiz</a>
    (a) art.html (b) Take the quiz (c) maths.html (d) https://example.com
  28. 28.🌐 Which one shows line numbers? (a) a web browser (b) a code editor (c) a web server
  29. 29.🏷️ Is </h1> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
  30. 30.🏷️ Every HTML tag starts with which sign? (a) [ (b) { (c) < (d) (
  31. 31.Which of these has a closing tag? (a) <meta> (b) <title> (c) <br> (d) <hr>
  32. 32.🔍 One closing tag is missing. Which one?
    <h1>Hello, world!
    <b>Fun facts</b>
    <h2>I love mangoes.</h2>
    (a) </h1> (b) </b> (c) </p> (d) </h2>
  33. 33.📝 Does <h1> have a closing tag, or is it an empty tag? (a) an empty tag (b) has a closing tag
  34. 34.🏷️ Is <p> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
  35. 35.🔗 Which address opens when you click this link?
    <a href="games.html">Art corner</a>
    (a) Art corner (b) games.html (c) about.html (d) contact.html
  36. 36.💬 Which text will NOT show on the page?
    <p>My best friend</p>
    <!-- <p>My pets</p> -->
    <p>Our school trip</p>
    (a) Our school trip (b) My best friend (c) My pets
  37. 37.💬 Which text will NOT show on the page?
    <!-- <p>The red kite</p> -->
    <p>Good morning!</p>
    <p>Our school trip</p>
    (a) Good morning! (b) Our school trip (c) The red kite
  38. 38.📄 Which part holds everything you see on the page? (a) the body (b) the head (c) the title (d) the doctype
  39. 39.🔢 In a basic web page file, which comes first: “<html>” or “<!DOCTYPE html>”? (a) <!DOCTYPE html> (b) <html>
  40. 40.🔍 One closing tag is missing. Which one?
    <small>Our school trip</small>
    <b>Cricket is fun.</b>
    <strong>My best friend
    (a) </b> (b) </small> (c) </strong> (d) </em>

Answer key

  1. <h1>
  2. an attribute
  3. </li>
  4. Language
  5. 2
  6. bullets
  7. on the browser tab
  8. is where we type code
  9. <li>
  10. sends pages over the net
  11. Our school bus
  12. map.png
  13. <ul>
  14. Art Gallery
  15. False
  16. False
  17. </h2>
  18. Cricket is fun.
  19. Play games
  20. Yes
  21. <body>
  22. Space Facts
  23. 2
  24. False
  25. opens web pages for us
  26. map.png
  27. https://example.com
  28. a code editor
  29. a closing tag
  30. <
  31. <title>
  32. </h1>
  33. has a closing tag
  34. an opening tag
  35. games.html
  36. My pets
  37. The red kite
  38. the body
  39. <!DOCTYPE html>
  40. </strong>

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