← HTML basics test lesson New set →

HTML Worksheet: Practice Test

HTML and CSS lesson 10: HTML basics test · Set 946 · 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.💬 How does an HTML comment start? (a) /* (b) <!-- (c) // (d) #
  2. 2.🔗 Which words do you click on?
    <a href="art.html">About us</a>
    (a) art.html (b) href (c) About us (d) Contact us
  3. 3.💬 How many paragraphs show on the page?
    <p>Our school trip</p>
    <p>Fun facts</p>
    <p>I love mangoes.</p>
    <!-- <p>The red kite</p> -->
  4. 4.🔍 Which is the odd one out? (a) answers page requests (b) has an address bar (c) opens web pages for us (d) turns HTML into a page
  5. 5.🔗 Where does this link open?
    <a href="art.html">Maths fun</a>
    (a) in the same tab (b) in a new tab
  6. 6.🖼️ Which picture file does the browser load?
    <img src="fort.jpg" alt="An old fort" width="400">
    (a) tiger.jpg (b) kite.png (c) fort.jpg (d) An old fort
  7. 7.🖼️ Which attribute of <img> sets how wide it is? (a) src (b) width (c) height (d) alt
  8. 8.🖼️ Does <img> need a closing tag? (a) Yes (b) No
  9. 9.📄 Where does <h1> go: in the head or in the body? (a) in the head (b) in the body
  10. 10.🔠 How many headings are in this code?
    <h1>My pets</h1>
    <h2>Our school trip</h2>
    <h2>The red kite</h2>
    <p>My best friend</p>
  11. 11.📋 How many items does this list show?
    <ol>
      <li>Papaya</li>
      <li>Litchi</li>
      <li>Grapes</li>
      <li>Jamun</li>
      <li>Guava</li>
    </ol>
  12. 12.📄 Can HTML on its own make tables? (a) No (b) Yes
  13. 13.📝 On how many lines does the browser show this paragraph?
    <p>Kites fly high<br>Stars shine</p>
  14. 14.🌐 Which one hosts websites online? (a) a web browser (b) a code editor (c) a web server
  15. 15.🏷️ Which is the closing tag for <b>? (a) <b> (b) <\b> (c) </b> (d) <b/>
  16. 16.🔍 Which line is missing its closing tag?
    line 1: <i>Hello, world!</i>
    line 2: <small>Fun facts</small>
    line 3: <h2>My pets
    (a) line 2 (b) line 3 (c) line 1
  17. 17.Which of these has a closing tag? (a) <meta> (b) <ul> (c) <img> (d) <input>
  18. 18.True or false: HTML on its own can make bullet lists. (a) False (b) True
  19. 19.🔠 How many <h1> headings should a page usually have? (a) 1 (b) 6 (c) 3 (d) 10
  20. 20.🔗 Which words do you click on?
    <a href="games.html">Contact us</a>
    (a) games.html (b) Visit the site (c) Contact us (d) href
  21. 21.🔠 Which heading shows the SMALLEST text: <h5>, <h3>, <h1> or <h4>? (a) <h4> (b) <h1> (c) <h3> (d) <h5>
  22. 22.🌐 Which one saves our .html files? (a) a web server (b) a web browser (c) a code editor
  23. 23.🏷️ Which is the closing tag for <h3>? (a) <h3> (b) <\h3> (c) </h3> (d) <h3/>
  24. 24.True or false: <li> shows bullet points. (a) False (b) True
  25. 25.📋 Does this list show bullets or numbers?
    <ul>
      <li>Papaya</li>
      <li>Litchi</li>
    </ul>
    (a) numbers (b) bullets
  26. 26.📄 What does the browser tab show for this page?
    <!DOCTYPE html>
    <html>
    <head>
      <title>My Hobbies</title>
    </head>
    <body>
      <h1>All about me</h1>
      <p>Try this poha.</p>
    </body>
    </html>
    (a) Try this poha. (b) index.html (c) All about me (d) My Hobbies
  27. 27.📝 What does <hr> draw? (a) a link (b) a line across the page (c) a table (d) a picture
  28. 28.🏷️ Is </title> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
  29. 29.Which of these is a closing tag? (a) <p> (b) <h1> (c) </b> (d) <body>
  30. 30.🏷️ What does a closing tag have that an opening tag does not? (a) a dollar $ (b) a dot . (c) a hash # (d) a slash /
  31. 31.🔤 In “HTML”, what does the L stand for? (a) Language (b) Link (c) Laptop (d) Line
  32. 32.🔠 Which heading shows the SMALLEST text: <h1>, <h5>, <h4> or <h6>? (a) <h5> (b) <h6> (c) <h1> (d) <h4>
  33. 33.🔢 In a basic web page file, which comes first: “<html>” or “<head>”? (a) <head> (b) <html>
  34. 34.🏷️ Is </li> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
  35. 35.🌐 Which one stores a website’s files? (a) a web server (b) a web browser (c) a code editor
  36. 36.📄 Can HTML on its own make a form? (a) Yes (b) No
  37. 37.True or false: <ol> shows bullet points. (a) True (b) False
  38. 38.Which of these is a closing tag? (a) <p> (b) <body> (c) <title> (d) </title>
  39. 39.🔠 How many headings are in this code?
    <h1>Good morning!</h1>
    <h4>My best friend</h4>
    <p>Hello, world!</p>
  40. 40.📄 What is the big heading shown on this page?
    <!DOCTYPE html>
    <html>
    <head>
      <title>Art Gallery</title>
    </head>
    <body>
      <h1>All about me</h1>
      <p>Here is my best one.</p>
    </body>
    </html>
    (a) Art Gallery (b) Here is my best one. (c) body (d) All about me

Answer key

  1. <!--
  2. About us
  3. 3
  4. answers page requests
  5. in the same tab
  6. fort.jpg
  7. width
  8. No
  9. in the body
  10. 3
  11. 5
  12. Yes
  13. 2
  14. a web server
  15. </b>
  16. line 3
  17. <ul>
  18. True
  19. 1
  20. Contact us
  21. <h5>
  22. a code editor
  23. </h3>
  24. False
  25. bullets
  26. My Hobbies
  27. a line across the page
  28. a closing tag
  29. </b>
  30. a slash /
  31. Language
  32. <h6>
  33. <html>
  34. a closing tag
  35. a web server
  36. Yes
  37. False
  38. </title>
  39. 2
  40. All about me

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