← HTML basics test lesson New set →

HTML Worksheet: Practice Test

HTML and CSS lesson 10: HTML basics test · Set 871 · 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 heading shows the BIGGEST text: <h5>, <h3>, <h1> or <h2>? (a) <h5> (b) <h3> (c) <h1> (d) <h2>
  2. 2.🔍 Which is the odd one out? (a) shows line numbers (b) is where we type code (c) stores a website’s files (d) colours code to help us
  3. 3.📋 How many items does this list show?
    <ol>
      <li>Banana</li>
      <li>Jamun</li>
      <li>Guava</li>
      <li>Litchi</li>
      <li>Orange</li>
      <li>Papaya</li>
    </ol>
  4. 4.🔗 Which address opens when you click this link?
    <a href="art.html">Maths fun</a>
    (a) Maths fun (b) art.html (c) news.html (d) quiz.html
  5. 5.🔠 Which tag is the least important heading? (a) <h1> (b) <p> (c) <h6> (d) <h3>
  6. 6.🔢 In a basic web page file, which comes FIRST? (a) <head> (b) </body> (c) </head> (d) <!DOCTYPE html>
  7. 7.🔠 Which heading shows the SMALLEST text: <h1>, <h6>, <h5> or <h3>? (a) <h3> (b) <h5> (c) <h1> (d) <h6>
  8. 8.🖼️ Which attribute of <img> is read by screen readers? (a) src (b) height (c) width (d) alt
  9. 9.Which of these is a closing tag? (a) <li> (b) <title> (c) <body> (d) </h1>
  10. 10.True or false: <ul> goes inside ul or ol. (a) True (b) False
  11. 11.📄 What does the browser tab show for this page?
    <!DOCTYPE html>
    <html>
    <head>
      <title>Cricket Club</title>
    </head>
    <body>
      <h1>All about me</h1>
      <p>We won by 5 runs.</p>
    </body>
    </html>
    (a) index.html (b) Cricket Club (c) We won by 5 runs. (d) All about me
  12. 12.📝 How many paragraphs does this code make?
    <p>Cricket is fun.</p>
    <p>The red kite</p>
    <p>The red kite</p>
  13. 13.🖼️ The picture cannot load. Which text does the browser show instead?
    <img src="bus.jpg" alt="Our school bus" width="200">
    (a) Our school bus (b) width (c) bus.jpg (d) An old fort
  14. 14.🔠 Which tag is used for the main title on a page? (a) <h6> (b) <br> (c) <p> (d) <h1>
  15. 15.📝 On how many lines does the browser show this paragraph?
    <p>Kites fly high<br>Stars shine</p>
  16. 16.💬 How many paragraphs show on the page?
    <p>My pets</p>
    <!-- <p>Rain today</p> -->
    <p>Hello, world!</p>
  17. 17.🔍 Which is the odd one out? (a) opens web pages for us (b) shows line numbers (c) is where we type code (d) saves our .html files
  18. 18.📄 Where does <a> go: in the head or in the body? (a) in the body (b) in the head
  19. 19.📝 How many paragraphs does this code make?
    <p>Cricket is fun.</p>
    <p>The red kite</p>
    <p>Our school trip</p>
    <p>Hello, world!</p>
    <p>Hello, world!</p>
    <h2>Good morning!</h2>
  20. 20.🔠 How many heading levels does HTML have? (a) 4 (b) 6 (c) 10 (d) 3
  21. 21.🖼️ The picture cannot load. Which text does the browser show instead?
    <img src="bus.jpg" alt="Our school bus" width="150">
    (a) Our school bus (b) An old fort (c) width (d) bus.jpg
  22. 22.Which of these is true of a web server? (a) opens web pages for us (b) has an address bar (c) saves our .html files (d) sends pages over the net
  23. 23.🔗 Which code links to about.html? (a) <link about.html> (b) <a src="about.html"> (c) <a href="about.html"> (d) <a alt="about.html">
  24. 24.🔗 Which address opens when you click this link?
    <a href="maths.html">Maths fun</a>
    (a) maths.html (b) Maths fun (c) art.html (d) news.html
  25. 25.🖼️ How many pixels wide is the picture drawn?
    <img src="map.png" alt="Map of India" width="300">
  26. 26.📋 How many items does this list show?
    <ol>
      <li>Litchi</li>
      <li>Mango</li>
      <li>Jamun</li>
      <li>Papaya</li>
      <li>Guava</li>
    </ol>
  27. 27.📄 Where does the text of <title> appear? (a) on the browser tab (b) at the bottom (c) in a big heading (d) nowhere
  28. 28.🖼️ Which attribute of <img> shows if the image fails? (a) src (b) width (c) height (d) alt
  29. 29.📋 Does this list show bullets or numbers?
    <ul>
      <li>Orange</li>
      <li>Grapes</li>
      <li>Litchi</li>
    </ul>
    (a) numbers (b) bullets
  30. 30.🖼️ Which picture file does the browser load?
    <img src="tiger.jpg" alt="A tiger asleep" width="150">
    (a) kite.png (b) tiger.jpg (c) map.png (d) A tiger asleep
  31. 31.📋 Which list shows the steps of a recipe best? (a) <br> (b) <ul> (c) <ol> (d) <hr>
  32. 32.📝 How many paragraphs does this code make?
    <p>The red kite</p>
    <p>Our school trip</p>
    <h2>My best friend</h2>
  33. 33.📝 Does <p> have a closing tag, or is it an empty tag? (a) has a closing tag (b) an empty tag
  34. 34.💬 How many paragraphs show on the page?
    <p>Hello, world!</p>
    <p>I love mangoes.</p>
    <p>Good morning!</p>
    <!-- <p>Rain today</p> -->
    <p>Our school trip</p>
  35. 35.Which of these is true of a web server? (a) saves our .html files (b) stores a website’s files (c) opens web pages for us (d) shows pages from the web
  36. 36.Which of these is an opening tag? (a) </b> (b) </li> (c) </p> (d) <h1>
  37. 37.🌐 Which one opens web pages for us? (a) a code editor (b) a web server (c) a web browser
  38. 38.💬 How many paragraphs show on the page?
    <!-- <p>Hello, world!</p> -->
    <!-- <p>Good morning!</p> -->
    <p>Rain today</p>
  39. 39.Which of these has a closing tag? (a) <hr> (b) <meta> (c) <br> (d) <p>
  40. 40.Which of these goes in the body? (a) <style> (b) <title> (c) <link rel="stylesheet"> (d) <h1>

Answer key

  1. <h1>
  2. stores a website’s files
  3. 6
  4. art.html
  5. <h6>
  6. <!DOCTYPE html>
  7. <h6>
  8. alt
  9. </h1>
  10. False
  11. Cricket Club
  12. 3
  13. Our school bus
  14. <h1>
  15. 2
  16. 2
  17. opens web pages for us
  18. in the body
  19. 5
  20. 6
  21. Our school bus
  22. sends pages over the net
  23. <a href="about.html">
  24. maths.html
  25. 300
  26. 5
  27. on the browser tab
  28. alt
  29. bullets
  30. tiger.jpg
  31. <ol>
  32. 2
  33. has a closing tag
  34. 4
  35. stores a website’s files
  36. <h1>
  37. a web browser
  38. 1
  39. <p>
  40. <h1>

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