← HTML basics test lesson New set →

HTML Worksheet: Practice Test

HTML and CSS lesson 10: HTML basics test · Set 494 · 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.📝 On how many lines does the browser show this paragraph?
    <p>Kites fly high<br>Rivers flow<br>Birds sing<br>Sky is blue<br>Roses are red</p>
  2. 2.Which of these is true of a code editor? (a) is where we type code (b) answers page requests (c) hosts websites online (d) stores a website’s files
  3. 3.🔠 How many headings are in this code?
    <h1>The red kite</h1>
    <p>Rain today</p>
    <p>My pets</p>
  4. 4.🔢 In a basic web page file, which comes LAST? (a) <!DOCTYPE html> (b) </body> (c) </html> (d) <head>
  5. 5.📄 Which part holds everything you see on the page? (a) the doctype (b) the body (c) the head (d) the title
  6. 6.🔍 One closing tag is missing. Which one?
    <strong>Fun facts</strong>
    <h1>The red kite</h1>
    <em>Good morning!
    (a) </em> (b) </strong> (c) </h1> (d) </b>
  7. 7.Which of these is a closing tag? (a) <li> (b) <body> (c) </b> (d) <h1>
  8. 8.🖼️ The picture cannot load. Which text does the browser show instead?
    <img src="bus.jpg" alt="Our school bus" width="150">
    (a) An old fort (b) bus.jpg (c) Our school bus (d) width
  9. 9.🔗 Which address opens when you click this link?
    <a href="art.html">Maths fun</a>
    (a) Maths fun (b) quiz.html (c) art.html (d) news.html
  10. 10.🖼️ How many pixels wide is the picture drawn?
    <img src="bus.jpg" alt="Our school bus" width="300">
  11. 11.True or false: <li> shows 1, 2, 3 numbers. (a) True (b) False
  12. 12.🔠 Which heading shows the SMALLEST text: <h4>, <h3>, <h1> or <h6>? (a) <h3> (b) <h4> (c) <h6> (d) <h1>
  13. 13.📄 Where does <style> go: in the head or in the body? (a) in the body (b) in the head
  14. 14.Which of these is an opening tag? (a) </li> (b) </p> (c) <li> (d) </h1>
  15. 15.📄 Where does the text of <title> appear? (a) at the bottom (b) in a big heading (c) nowhere (d) on the browser tab
  16. 16.🌐 Which one answers page requests? (a) a web server (b) a code editor (c) a web browser
  17. 17.🔍 Which is the odd one out? (a) shows pages from the web (b) turns HTML into a page (c) opens web pages for us (d) colours code to help us
  18. 18.📝 On how many lines does the browser show this paragraph?
    <p>Kites fly high<br>Sky is blue</p>
  19. 19.🔗 Which words do you click on?
    <a href="quiz.html">Take the quiz</a>
    (a) Play games (b) href (c) quiz.html (d) Take the quiz
  20. 20.🏷️ Which is the closing tag for <h2>? (a) </h2> (b) <\h2> (c) <h2/> (d) <h2>
  21. 21.True or false: <li> is an empty tag. (a) True (b) False
  22. 22.🔠 Which tag is the least important heading? (a) <h3> (b) <h1> (c) <p> (d) <h6>
  23. 23.🖼️ The picture cannot load. Which text does the browser show instead?
    <img src="tiger.jpg" alt="A tiger asleep" width="200">
    (a) width (b) A tiger asleep (c) tiger.jpg (d) A red kite
  24. 24.🔢 In a basic web page file, which comes first: “</html>” or “</body>”? (a) </html> (b) </body>
  25. 25.📝 What does <hr> draw? (a) a line across the page (b) a picture (c) a table (d) a link
  26. 26.🔢 In a basic web page file, which comes first: “<html>” or “<!DOCTYPE html>”? (a) <!DOCTYPE html> (b) <html>
  27. 27.Which of these is a closing tag? (a) <li> (b) <h1> (c) <body> (d) </li>
  28. 28.📄 Where does <p> go: in the head or in the body? (a) in the head (b) in the body
  29. 29.🔍 Which line is missing its closing tag?
    line 1: <i>Cricket is fun.
    line 2: <h2>Good morning!</h2>
    line 3: <strong>Our school trip</strong>
    (a) line 2 (b) line 3 (c) line 1
  30. 30.💬 How many paragraphs show on the page?
    <!-- <p>My best friend</p> -->
    <p>Good morning!</p>
    <p>Cricket is fun.</p>
  31. 31.🔗 Where does this link open?
    <a href="contact.html">Maths fun</a>
    (a) in the same tab (b) in a new tab
  32. 32.📋 How many items does this list show?
    <ul>
      <li>Papaya</li>
      <li>Guava</li>
      <li>Jamun</li>
      <li>Litchi</li>
      <li>Grapes</li>
    </ul>
  33. 33.📝 How many paragraphs does this code make?
    <p>My best friend</p>
    <p>Good morning!</p>
    <p>Hello, world!</p>
    <h2>My pets</h2>
  34. 34.🔗 Which tag makes a clickable link? (a) <p> (b) <link> (c) <a> (d) <img>
  35. 35.🔗 Which words do you click on?
    <a href="games.html">Visit the site</a>
    (a) Maths fun (b) Visit the site (c) games.html (d) href
  36. 36.📝 How many paragraphs does this code make?
    <p>My pets</p>
    <p>The red kite</p>
    <p>Rain today</p>
    <p>The red kite</p>
  37. 37.📄 Can HTML on its own add up two numbers? (a) No (b) Yes
  38. 38.🔤 In “HTML”, what do the letters HT stand for? (a) High Tech (b) Hot Tags (c) HyperText (d) Home Text
  39. 39.🔗 What does target="_blank" do to a link? (a) makes it bold (b) hides the link (c) makes it blank (d) opens it in a new tab
  40. 40.🖼️ How many pixels wide is the picture drawn?
    <img src="kite.png" alt="A red kite" width="400">

Answer key

  1. 5
  2. is where we type code
  3. 1
  4. </html>
  5. the body
  6. </em>
  7. </b>
  8. Our school bus
  9. art.html
  10. 300
  11. False
  12. <h6>
  13. in the head
  14. <li>
  15. on the browser tab
  16. a web server
  17. colours code to help us
  18. 2
  19. Take the quiz
  20. </h2>
  21. False
  22. <h6>
  23. A tiger asleep
  24. </body>
  25. a line across the page
  26. <!DOCTYPE html>
  27. </li>
  28. in the body
  29. line 1
  30. 2
  31. in the same tab
  32. 5
  33. 3
  34. <a>
  35. Visit the site
  36. 4
  37. No
  38. HyperText
  39. opens it in a new tab
  40. 400

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