← HTML basics test lesson New set →

HTML Worksheet: Practice Test

HTML and CSS lesson 10: HTML basics test · Set 811 · 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 address opens when you click this link?
    <a href="games.html">Art corner</a>
    (a) contact.html (b) Art corner (c) games.html (d) about.html
  2. 2.🔗 What does target="_blank" do to a link? (a) makes it bold (b) makes it blank (c) opens it in a new tab (d) hides the link
  3. 3.🔗 Where does this link open?
    <a href="art.html">Play games</a>
    (a) in the same tab (b) in a new tab
  4. 4.🖼️ The picture cannot load. Which text does the browser show instead?
    <img src="moon.png" alt="The full moon" width="50">
    (a) Our school bus (b) width (c) moon.png (d) The full moon
  5. 5.True or false: <ul> goes inside ul or ol. (a) True (b) False
  6. 6.📋 Which list tag is an ordered list? (a) <ol> (b) <ul> (c) <li>
  7. 7.🌍 Which program shows a web page to us? (a) a calculator (b) a music player (c) a paint program (d) a web browser
  8. 8.🖼️ Which picture file does the browser load?
    <img src="bus.jpg" alt="Our school bus" width="250">
    (a) Our school bus (b) tiger.jpg (c) fort.jpg (d) bus.jpg
  9. 9.🔍 Which line is missing its closing tag?
    line 1: <p>My pets</p>
    line 2: <i>Our school trip</i>
    line 3: <small>Rain today
    (a) line 2 (b) line 1 (c) line 3
  10. 10.💬 Which text will NOT show on the page?
    <p>Hello, world!</p>
    <!-- <p>I love mangoes.</p> -->
    <p>Our school trip</p>
    (a) Our school trip (b) I love mangoes. (c) Hello, world!
  11. 11.📝 On how many lines does the browser show this paragraph?
    <p>Kites fly high<br>Rivers flow<br>Roses are red</p>
  12. 12.🖼️ Which picture file does the browser load?
    <img src="kite.png" alt="A red kite" width="250">
    (a) cake.jpg (b) kite.png (c) A red kite (d) map.png
  13. 13.🔗 Which words do you click on?
    <a href="about.html">Contact us</a>
    (a) about.html (b) href (c) Visit the site (d) Contact us
  14. 14.🖼️ The picture cannot load. Which text does the browser show instead?
    <img src="dog.jpg" alt="A happy dog" width="250">
    (a) A happy dog (b) The full moon (c) width (d) dog.jpg
  15. 15.True or false: <a> goes in the head. (a) False (b) True
  16. 16.🔗 Which words do you click on?
    <a href="https://example.com">Art corner</a>
    (a) Art corner (b) https://example.com (c) School news (d) href
  17. 17.📄 Can HTML on its own make bullet lists? (a) Yes (b) No
  18. 18.True or false: a web server shows pages from the web. (a) False (b) True
  19. 19.True or false: in <img>, height names the picture file. (a) False (b) True
  20. 20.📋 Which list tag lists steps in order? (a) <ol> (b) <ul> (c) <li>
  21. 21.🖼️ The picture cannot load. Which text does the browser show instead?
    <img src="fort.jpg" alt="An old fort" width="400">
    (a) An old fort (b) A tiger asleep (c) fort.jpg (d) width
  22. 22.🔢 In a basic web page file, which comes first: “<body>” or “</html>”? (a) <body> (b) </html>
  23. 23.True or false: in <img>, height sets how tall it is. (a) False (b) True
  24. 24.🔠 Which heading shows the BIGGEST text: <h5>, <h3>, <h1> or <h2>? (a) <h2> (b) <h3> (c) <h1> (d) <h5>
  25. 25.📝 Does <h1> have a closing tag, or is it an empty tag? (a) has a closing tag (b) an empty tag
  26. 26.🔍 One closing tag is missing. Which one?
    <strong>Good morning!</strong>
    <h2>Hello, world!</h2>
    <h3>My best friend
    (a) </em> (b) </strong> (c) </h2> (d) </h3>
  27. 27.True or false: <title> goes in the head. (a) False (b) True
  28. 28.🔢 In a basic web page file, which comes first: “<body>” or “</body>”? (a) <body> (b) </body>
  29. 29.Which of these is a closing tag? (a) <b> (b) </h1> (c) <title> (d) <li>
  30. 30.📝 How many paragraphs does this code make?
    <p>My pets</p>
    <p>The red kite</p>
    <p>Cricket is fun.</p>
    <h2>Rain today</h2>
    <h2>Rain today</h2>
  31. 31.True or false: <img> goes in the head. (a) False (b) True
  32. 32.True or false: HTML on its own can make links to pages. (a) False (b) True
  33. 33.📋 Does this list show bullets or numbers?
    <ul>
      <li>Guava</li>
      <li>Jamun</li>
    </ul>
    (a) numbers (b) bullets
  34. 34.📝 On how many lines does the browser show this paragraph?
    <p>Stars shine<br>Birds sing</p>
  35. 35.📝 You type 5 spaces between two words in a <p>. How does the browser show them? (a) as a dot (b) as a new line (c) as 5 spaces (d) as one space
  36. 36.True or false: <ul> shows 1, 2, 3 numbers. (a) False (b) True
  37. 37.Which of these is true of a code editor? (a) shows pages from the web (b) is where we type code (c) answers page requests (d) sends pages over the net
  38. 38.📝 Does <br> have a closing tag, or is it an empty tag? (a) has a closing tag (b) an empty tag
  39. 39.True or false: in <img>, src shows if the image fails. (a) False (b) True
  40. 40.📋 How many items does this list show?
    <ol>
      <li>Mango</li>
      <li>Jamun</li>
      <li>Litchi</li>
      <li>Grapes</li>
    </ol>

Answer key

  1. games.html
  2. opens it in a new tab
  3. in the same tab
  4. The full moon
  5. False
  6. <ol>
  7. a web browser
  8. bus.jpg
  9. line 3
  10. I love mangoes.
  11. 3
  12. kite.png
  13. Contact us
  14. A happy dog
  15. False
  16. Art corner
  17. Yes
  18. False
  19. False
  20. <ol>
  21. An old fort
  22. <body>
  23. True
  24. <h1>
  25. has a closing tag
  26. </h3>
  27. True
  28. <body>
  29. </h1>
  30. 3
  31. False
  32. True
  33. bullets
  34. 2
  35. as one space
  36. False
  37. is where we type code
  38. an empty tag
  39. False
  40. 4

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