← HTML basics test lesson New set →

HTML Worksheet: Practice Test

HTML and CSS lesson 10: HTML basics test · Set 95 · 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.📄 What does the browser tab show for this page?
    <!DOCTYPE html>
    <html>
    <head>
      <title>Art Gallery</title>
    </head>
    <body>
      <h1>All about me</h1>
      <p>Try this poha.</p>
    </body>
    </html>
    (a) index.html (b) All about me (c) Art Gallery (d) Try this poha.
  2. 2.💬 How many paragraphs show on the page?
    <!-- <p>Cricket is fun.</p> -->
    <p>Rain today</p>
    <p>Fun facts</p>
    <p>The red kite</p>
  3. 3.🏷️ Which is the closing tag for <i>? (a) </i> (b) <i> (c) <i/> (d) <\i>
  4. 4.📄 Can HTML on its own make bullet lists? (a) No (b) Yes
  5. 5.🖼️ The picture cannot load. Which text does the browser show instead?
    <img src="cake.jpg" alt="Birthday cake" width="200">
    (a) width (b) Birthday cake (c) cake.jpg (d) A happy dog
  6. 6.📋 What number does the browser show next to “Papaya”?
    <ol>
      <li>Banana</li>
      <li>Grapes</li>
      <li>Papaya</li>
      <li>Litchi</li>
      <li>Mango</li>
    </ol>
  7. 7.🔠 Which heading shows the BIGGEST text: <h6>, <h3>, <h4> or <h1>? (a) <h6> (b) <h3> (c) <h1> (d) <h4>
  8. 8.🔗 Which words do you click on?
    <a href="quiz.html">School news</a>
    (a) School news (b) Take the quiz (c) quiz.html (d) href
  9. 9.💬 Does the browser show comments on the page? (a) Yes (b) No
  10. 10.💬 Which text will NOT show on the page?
    <p>Fun facts</p>
    <p>My best friend</p>
    <!-- <p>Good morning!</p> -->
    (a) Fun facts (b) Good morning! (c) My best friend
  11. 11.🖼️ How many pixels wide is the picture drawn?
    <img src="bus.jpg" alt="Our school bus" width="50">
  12. 12.📋 Does this list show bullets or numbers?
    <ol>
      <li>Papaya</li>
      <li>Litchi</li>
    </ol>
    (a) bullets (b) numbers
  13. 13.📄 Where does <meta charset="utf-8"> go: in the head or in the body? (a) in the head (b) in the body
  14. 14.Which of these has a closing tag? (a) <br> (b) <hr> (c) <p> (d) <meta>
  15. 15.📝 What does <hr> draw? (a) a table (b) a line across the page (c) a link (d) a picture
  16. 16.True or false: in <img>, src names the picture file. (a) False (b) True
  17. 17.🔢 In a basic web page file, which comes FIRST? (a) </body> (b) </head> (c) <html> (d) <!DOCTYPE html>
  18. 18.📋 Does this list show bullets or numbers?
    <ol>
      <li>Guava</li>
      <li>Mango</li>
    </ol>
    (a) numbers (b) bullets
  19. 19.🔠 Which heading shows the SMALLEST text: <h4>, <h2>, <h5> or <h6>? (a) <h6> (b) <h5> (c) <h4> (d) <h2>
  20. 20.📝 On how many lines does the browser show this paragraph?
    <p>Birds sing<br>Stars shine<br>Roses are red<br>Sky is blue</p>
  21. 21.🔗 Which tag makes a clickable link? (a) <a> (b) <img> (c) <link> (d) <p>
  22. 22.📄 Can HTML on its own add pictures to a page? (a) No (b) Yes
  23. 23.🌐 Which one stores a website’s files? (a) a code editor (b) a web server (c) a web browser
  24. 24.🔗 Which address opens when you click this link?
    <a href="quiz.html">Maths fun</a>
    (a) Maths fun (b) games.html (c) quiz.html (d) about.html
  25. 25.True or false: HTML on its own cannot run a game loop. (a) True (b) False
  26. 26.🖼️ How many pixels wide is the picture drawn?
    <img src="moon.png" alt="The full moon" width="150">
  27. 27.📝 How many paragraphs does this code make?
    <p>Hello, world!</p>
    <h2>My pets</h2>
    <h2>Good morning!</h2>
    <h2>Good morning!</h2>
  28. 28.🔢 In a basic web page file, which comes first: “<!DOCTYPE html>” or “</html>”? (a) </html> (b) <!DOCTYPE html>
  29. 29.Which of these is true of a code editor? (a) shows pages from the web (b) has an address bar (c) hosts websites online (d) is where we type code
  30. 30.🔠 Which tag is the least important heading? (a) <p> (b) <h3> (c) <h6> (d) <h1>
  31. 31.Which of these is an empty tag? (a) <h1> (b) <p> (c) <title> (d) <meta>
  32. 32.🔗 Which words do you click on?
    <a href="games.html">Maths fun</a>
    (a) Art corner (b) Maths fun (c) href (d) games.html
  33. 33.📝 Does <ul> have a closing tag, or is it an empty tag? (a) has a closing tag (b) an empty tag
  34. 34.🖼️ Which picture file does the browser load?
    <img src="kite.png" alt="A red kite" width="400">
    (a) map.png (b) cake.jpg (c) kite.png (d) A red kite
  35. 35.🌐 Which one shows line numbers? (a) a web browser (b) a web server (c) a code editor
  36. 36.🖼️ Does <img> need a closing tag? (a) Yes (b) No
  37. 37.🔠 Which heading shows the SMALLEST text: <h6>, <h5>, <h3> or <h1>? (a) <h1> (b) <h5> (c) <h6> (d) <h3>
  38. 38.True or false: <li> has a closing tag. (a) True (b) False
  39. 39.🏷️ Is </title> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
  40. 40.🖼️ The picture cannot load. Which text does the browser show instead?
    <img src="map.png" alt="Map of India" width="250">
    (a) Map of India (b) map.png (c) Birthday cake (d) width

Answer key

  1. Art Gallery
  2. 3
  3. </i>
  4. Yes
  5. Birthday cake
  6. 3
  7. <h1>
  8. School news
  9. No
  10. Good morning!
  11. 50
  12. numbers
  13. in the head
  14. <p>
  15. a line across the page
  16. True
  17. <!DOCTYPE html>
  18. numbers
  19. <h6>
  20. 4
  21. <a>
  22. Yes
  23. a web server
  24. quiz.html
  25. True
  26. 150
  27. 1
  28. <!DOCTYPE html>
  29. is where we type code
  30. <h6>
  31. <meta>
  32. Maths fun
  33. has a closing tag
  34. kite.png
  35. a code editor
  36. No
  37. <h6>
  38. True
  39. a closing tag
  40. Map of India

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