← HTML basics test lesson New set →

HTML Worksheet: Practice Test

HTML and CSS lesson 10: HTML basics test · Set 17 · 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.🔢 In a basic web page file, which comes LAST? (a) </body> (b) <!DOCTYPE html> (c) <head> (d) </html>
  2. 2.📝 What does <br> do? (a) makes a list (b) starts a new line (c) adds a picture (d) makes text bold
  3. 3.📋 Which list tag shows 1, 2, 3 numbers? (a) <ul> (b) <ol> (c) <li>
  4. 4.True or false: <table> goes in the body. (a) True (b) False
  5. 5.📋 Which list tag shows bullet points? (a) <ul> (b) <ol> (c) <li>
  6. 6.True or false: HTML on its own can make bullet lists. (a) False (b) True
  7. 7.💬 How many paragraphs show on the page?
    <!-- <p>Our school trip</p> -->
    <!-- <p>Cricket is fun.</p> -->
    <p>Fun facts</p>
  8. 8.📋 How many items does this list show?
    <ol>
      <li>Grapes</li>
      <li>Litchi</li>
      <li>Papaya</li>
      <li>Guava</li>
    </ol>
  9. 9.🔗 Which address opens when you click this link?
    <a href="quiz.html">Take the quiz</a>
    (a) Take the quiz (b) about.html (c) games.html (d) quiz.html
  10. 10.True or false: a code editor colours code to help us. (a) True (b) False
  11. 11.Which of these is an opening tag? (a) <p> (b) </p> (c) </li> (d) </body>
  12. 12.🔗 What does target="_blank" do to a link? (a) hides the link (b) makes it blank (c) makes it bold (d) opens it in a new tab
  13. 13.🏷️ Is </li> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
  14. 14.🖼️ Why do we add alt text to an image? (a) to describe the image (b) to colour it (c) to make it bigger (d) to load it faster
  15. 15.💬 How many paragraphs show on the page?
    <p>My pets</p>
    <!-- <p>Hello, world!</p> -->
    <p>I love mangoes.</p>
  16. 16.🔗 Which address opens when you click this link?
    <a href="games.html">Maths fun</a>
    (a) contact.html (b) about.html (c) Maths fun (d) games.html
  17. 17.🔠 How many headings are in this code?
    <h1>My best friend</h1>
    <h4>Fun facts</h4>
    <h2>Fun facts</h2>
  18. 18.📋 Does this list show bullets or numbers?
    <ol>
      <li>Grapes</li>
      <li>Guava</li>
      <li>Jamun</li>
    </ol>
    (a) bullets (b) numbers
  19. 19.💬 Which text will NOT show on the page?
    <!-- <p>Fun facts</p> -->
    <p>Rain today</p>
    <p>My pets</p>
    (a) Rain today (b) My pets (c) Fun facts
  20. 20.🔗 Where does this link open?
    <a href="games.html">Contact us</a>
    (a) in a new tab (b) in the same tab
  21. 21.🔗 Which address opens when you click this link?
    <a href="news.html">Contact us</a>
    (a) Contact us (b) games.html (c) news.html (d) quiz.html
  22. 22.🔗 Which address opens when you click this link?
    <a href="quiz.html">Art corner</a>
    (a) quiz.html (b) games.html (c) about.html (d) Art corner
  23. 23.💬 Does the browser show comments on the page? (a) No (b) Yes
  24. 24.💬 Which text will NOT show on the page?
    <p>My best friend</p>
    <!-- <p>Rain today</p> -->
    <p>The red kite</p>
    (a) My best friend (b) The red kite (c) Rain today
  25. 25.📋 Does this list show bullets or numbers?
    <ul>
      <li>Mango</li>
      <li>Litchi</li>
      <li>Orange</li>
    </ul>
    (a) numbers (b) bullets
  26. 26.🖼️ Which picture file does the browser load?
    <img src="tiger.jpg" alt="A tiger asleep" width="150">
    (a) map.png (b) A tiger asleep (c) tiger.jpg (d) kite.png
  27. 27.Which of these is an empty tag? (a) <li> (b) <b> (c) <title> (d) <meta>
  28. 28.🖼️ Which attribute of <img> shows if the image fails? (a) width (b) height (c) src (d) alt
  29. 29.🖼️ Which tag puts a picture on a page? (a) <p> (b) <a> (c) <img> (d) <pic>
  30. 30.💬 Which text will NOT show on the page?
    <p>My pets</p>
    <p>The red kite</p>
    <!-- <p>Rain today</p> -->
    <p>I love mangoes.</p>
    (a) I love mangoes. (b) The red kite (c) My pets (d) Rain today
  31. 31.📋 What number does the browser show next to “Grapes”?
    <ol>
      <li>Litchi</li>
      <li>Grapes</li>
      <li>Orange</li>
    </ol>
  32. 32.True or false: <img> goes in the body. (a) True (b) False
  33. 33.📋 Which list tag lists things in any order? (a) <li> (b) <ul> (c) <ol>
  34. 34.🏷️ Is <p> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
  35. 35.🖼️ The picture cannot load. Which text does the browser show instead?
    <img src="tiger.jpg" alt="A tiger asleep" width="100">
    (a) width (b) A tiger asleep (c) tiger.jpg (d) A red kite
  36. 36.📄 Where does <p> go: in the head or in the body? (a) in the body (b) in the head
  37. 37.📄 Can HTML on its own run a game loop? (a) Yes (b) No
  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 do we need to write HTML? (a) a printer (b) a paintbrush (c) a plain text editor (d) a microphone
  40. 40.🔢 In a basic web page file, which comes FIRST? (a) <html> (b) </html> (c) <!DOCTYPE html> (d) </head>

Answer key

  1. </html>
  2. starts a new line
  3. <ol>
  4. True
  5. <ul>
  6. True
  7. 1
  8. 4
  9. quiz.html
  10. True
  11. <p>
  12. opens it in a new tab
  13. a closing tag
  14. to describe the image
  15. 2
  16. games.html
  17. 3
  18. numbers
  19. Fun facts
  20. in the same tab
  21. news.html
  22. quiz.html
  23. No
  24. Rain today
  25. bullets
  26. tiger.jpg
  27. <meta>
  28. alt
  29. <img>
  30. Rain today
  31. 2
  32. True
  33. <ul>
  34. an opening tag
  35. A tiger asleep
  36. in the body
  37. No
  38. HyperText
  39. a plain text editor
  40. <!DOCTYPE html>

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