← HTML basics test lesson New set →

HTML Worksheet: Practice Test

HTML and CSS lesson 10: HTML basics test · Set 387 · 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.🔗 Where does this link open?
    <a href="news.html" target="_blank">Visit the site</a>
    (a) in a new tab (b) in the same tab
  2. 2.🖼️ How many pixels wide is the picture drawn?
    <img src="moon.png" alt="The full moon" width="300">
  3. 3.🔠 Are headings shown in bold by default? (a) No (b) Yes
  4. 4.📄 Can HTML on its own make links to pages? (a) No (b) Yes
  5. 5.Which of these has a closing tag? (a) <input> (b) <h1> (c) <hr> (d) <br>
  6. 6.🧩 An opening tag + content + a closing tag together make an ___. (a) attribute (b) editor (c) address (d) element
  7. 7.💬 Does the browser show comments on the page? (a) No (b) Yes
  8. 8.📝 Does <input> have a closing tag, or is it an empty tag? (a) an empty tag (b) has a closing tag
  9. 9.🔠 Which heading shows the BIGGEST text: <h6>, <h4>, <h2> or <h5>? (a) <h6> (b) <h5> (c) <h4> (d) <h2>
  10. 10.📝 Does <b> have a closing tag, or is it an empty tag? (a) has a closing tag (b) an empty tag
  11. 11.🔢 In a basic web page file, which comes LAST? (a) </html> (b) </body> (c) <html> (d) </head>
  12. 12.Which of these is an opening tag? (a) </title> (b) <title> (c) </h1> (d) </p>
  13. 13.🔍 One closing tag is missing. Which one?
    <u>My pets</u>
    <i>Our school trip
    <h3>I love mangoes.</h3>
    (a) </u> (b) </h3> (c) </h1> (d) </i>
  14. 14.💬 Which text will NOT show on the page?
    <p>Hello, world!</p>
    <!-- <p>Good morning!</p> -->
    <p>Rain today</p>
    (a) Rain today (b) Good morning! (c) Hello, world!
  15. 15.🔤 In “HTML”, what does the M stand for? (a) Markup (b) Modern (c) Machine (d) Mouse
  16. 16.🔠 Which tag is used for the main title on a page? (a) <p> (b) <br> (c) <h1> (d) <h6>
  17. 17.🖼️ Which picture file does the browser load?
    <img src="map.png" alt="Map of India" width="200">
    (a) cake.jpg (b) map.png (c) Map of India (d) dog.jpg
  18. 18.🔍 One closing tag is missing. Which one?
    <h1>Good morning!</h1>
    <small>My pets
    <p>Hello, world!</p>
    (a) </p> (b) </b> (c) </h1> (d) </small>
  19. 19.Which of these goes in the body? (a) <link rel="stylesheet"> (b) <meta charset="utf-8"> (c) <title> (d) <ul>
  20. 20.📋 Which list shows the steps of a recipe best? (a) <ul> (b) <br> (c) <ol> (d) <hr>
  21. 21.🖼️ The picture cannot load. Which text does the browser show instead?
    <img src="map.png" alt="Map of India" width="250">
    (a) width (b) map.png (c) Map of India (d) Birthday cake
  22. 22.🏷️ Which is the closing tag for <h2>? (a) </h2> (b) <\h2> (c) <h2> (d) <h2/>
  23. 23.🔠 Which heading shows the BIGGEST text: <h1>, <h5>, <h3> or <h6>? (a) <h6> (b) <h5> (c) <h3> (d) <h1>
  24. 24.📋 Which list tag is an ordered list? (a) <ol> (b) <ul> (c) <li>
  25. 25.🔗 Which words do you click on?
    <a href="about.html">School news</a>
    (a) School news (b) Take the quiz (c) href (d) about.html
  26. 26.🔢 In a basic web page file, which comes first: “<!DOCTYPE html>” or “<html>”? (a) <!DOCTYPE html> (b) <html>
  27. 27.🏷️ Is </li> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
  28. 28.🔠 Which heading shows the SMALLEST text: <h6>, <h3>, <h1> or <h2>? (a) <h1> (b) <h3> (c) <h2> (d) <h6>
  29. 29.🖼️ How many pixels wide is the picture drawn?
    <img src="dog.jpg" alt="A happy dog" width="150">
  30. 30.Which of these goes in the body? (a) <img> (b) <style> (c) <link rel="stylesheet"> (d) <title>
  31. 31.🔍 One closing tag is missing. Which one?
    <strong>I love mangoes.
    <h1>Hello, world!</h1>
    <i>Rain today</i>
    (a) </p> (b) </h1> (c) </strong> (d) </i>
  32. 32.True or false: <meta charset="utf-8"> goes in the head. (a) False (b) True
  33. 33.🔗 Which words do you click on?
    <a href="https://example.com">About us</a>
    (a) About us (b) https://example.com (c) Contact us (d) href
  34. 34.📝 Does <h1> have a closing tag, or is it an empty tag? (a) an empty tag (b) has a closing tag
  35. 35.🔗 Which words do you click on?
    <a href="https://example.com">Visit the site</a>
    (a) Maths fun (b) https://example.com (c) href (d) Visit the site
  36. 36.🏷️ Which is the closing tag for <i>? (a) <\i> (b) </i> (c) <i/> (d) <i>
  37. 37.📋 What number does the browser show next to “Litchi”?
    <ol>
      <li>Orange</li>
      <li>Jamun</li>
      <li>Litchi</li>
      <li>Papaya</li>
      <li>Grapes</li>
    </ol>
  38. 38.📋 Which list suits a shopping list in any order? (a) <br> (b) <ul> (c) <ol> (d) <hr>
  39. 39.🔠 How many headings are in this code?
    <h1>The red kite</h1>
    <p>Rain today</p>
    <p>Good morning!</p>
    <h3>Rain today</h3>
  40. 40.Which of these is true of a web server? (a) turns HTML into a page (b) opens web pages for us (c) shows pages from the web (d) hosts websites online

Answer key

  1. in a new tab
  2. 300
  3. Yes
  4. Yes
  5. <h1>
  6. element
  7. No
  8. an empty tag
  9. <h2>
  10. has a closing tag
  11. </html>
  12. <title>
  13. </i>
  14. Good morning!
  15. Markup
  16. <h1>
  17. map.png
  18. </small>
  19. <ul>
  20. <ol>
  21. Map of India
  22. </h2>
  23. <h1>
  24. <ol>
  25. School news
  26. <!DOCTYPE html>
  27. a closing tag
  28. <h6>
  29. 150
  30. <img>
  31. </strong>
  32. True
  33. About us
  34. has a closing tag
  35. Visit the site
  36. </i>
  37. 3
  38. <ul>
  39. 2
  40. hosts websites online

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