← HTML basics test lesson New set →

HTML Worksheet: Practice Test

HTML and CSS lesson 10: HTML basics test · Set 869 · 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.🔍 One closing tag is missing. Which one?
    <h3>My best friend</h3>
    <h2>I love mangoes.</h2>
    <em>My pets
    (a) </u> (b) </em> (c) </h3> (d) </h2>
  2. 2.🖼️ Which attribute of <img> sets how tall it is? (a) src (b) alt (c) width (d) height
  3. 3.📝 What does <p> make? (a) a link (b) a paragraph (c) a picture (d) a table
  4. 4.🔗 Which words do you click on?
    <a href="games.html">About us</a>
    (a) games.html (b) Contact us (c) href (d) About us
  5. 5.📄 Which part holds everything you see on the page? (a) the doctype (b) the head (c) the body (d) the title
  6. 6.📛 In <a href="x.html">, what is href? (a) an element name (b) a comment (c) an attribute (d) a closing tag
  7. 7.🏷️ Which is the closing tag for <b>? (a) <b> (b) </b> (c) <\b> (d) <b/>
  8. 8.🔗 Which words do you click on?
    <a href="https://example.com">Play games</a>
    (a) https://example.com (b) Play games (c) href (d) About us
  9. 9.📋 Does this list show bullets or numbers?
    <ol>
      <li>Papaya</li>
      <li>Litchi</li>
      <li>Mango</li>
    </ol>
    (a) bullets (b) numbers
  10. 10.🖼️ Which attribute of <img> names the picture file? (a) width (b) height (c) src (d) alt
  11. 11.📝 Does <img> have a closing tag, or is it an empty tag? (a) has a closing tag (b) an empty tag
  12. 12.📄 What is the big heading shown on this page?
    <!DOCTYPE html>
    <html>
    <head>
      <title>Space Facts</title>
    </head>
    <body>
      <h1>Match report</h1>
      <p>I like to read.</p>
    </body>
    </html>
    (a) body (b) Space Facts (c) Match report (d) I like to read.
  13. 13.📋 How many items does this list show?
    <ul>
      <li>Jamun</li>
      <li>Banana</li>
      <li>Grapes</li>
      <li>Papaya</li>
    </ul>
  14. 14.True or false: a web browser turns HTML into a page. (a) False (b) True
  15. 15.📝 How many paragraphs does this code make?
    <p>Hello, world!</p>
    <p>Rain today</p>
    <p>Cricket is fun.</p>
    <p>My pets</p>
    <h2>Rain today</h2>
  16. 16.True or false: <li> shows 1, 2, 3 numbers. (a) False (b) True
  17. 17.🏷️ What does a closing tag have that an opening tag does not? (a) a slash / (b) a hash # (c) a dot . (d) a dollar $
  18. 18.📝 What does <hr> draw? (a) a picture (b) a link (c) a table (d) a line across the page
  19. 19.True or false: <ul> goes inside ul or ol. (a) True (b) False
  20. 20.🏷️ Is </body> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
  21. 21.True or false: <ul> shows bullet points. (a) False (b) True
  22. 22.🔗 Where does this link open?
    <a href="art.html" target="_blank">Art corner</a>
    (a) in a new tab (b) in the same tab
  23. 23.🔢 In a basic web page file, which comes first: “</head>” or “<html>”? (a) </head> (b) <html>
  24. 24.True or false: a web server shows pages from the web. (a) False (b) True
  25. 25.🖼️ Does <img> need a closing tag? (a) Yes (b) No
  26. 26.🏷️ Is <li> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
  27. 27.📄 Where does the text of <title> appear? (a) nowhere (b) on the browser tab (c) in a big heading (d) at the bottom
  28. 28.🔠 Which heading shows the BIGGEST text: <h3>, <h4>, <h1> or <h5>? (a) <h1> (b) <h3> (c) <h4> (d) <h5>
  29. 29.🔠 Which tag is the least important heading? (a) <p> (b) <h3> (c) <h1> (d) <h6>
  30. 30.💬 Which text will NOT show on the page?
    <p>My best friend</p>
    <p>Good morning!</p>
    <!-- <p>Our school trip</p> -->
    (a) Good morning! (b) Our school trip (c) My best friend
  31. 31.📋 Which list tag is one item of a list? (a) <li> (b) <ul> (c) <ol>
  32. 32.🖼️ Which picture file does the browser load?
    <img src="cake.jpg" alt="Birthday cake" width="200">
    (a) cake.jpg (b) Birthday cake (c) moon.png (d) dog.jpg
  33. 33.🔠 Which heading shows the SMALLEST text: <h1>, <h2>, <h4> or <h6>? (a) <h4> (b) <h2> (c) <h1> (d) <h6>
  34. 34.📋 Which tag goes around each item of a list? (a) <p> (b) <ul> (c) <li> (d) <ol>
  35. 35.True or false: <ul> is an empty tag. (a) False (b) True
  36. 36.Which of these is true of a code editor? (a) sends pages over the net (b) stores a website’s files (c) turns HTML into a page (d) saves our .html files
  37. 37.💬 Does the browser show comments on the page? (a) No (b) Yes
  38. 38.🏷️ Is <b> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
  39. 39.🔗 Which address opens when you click this link?
    <a href="about.html">School news</a>
    (a) https://example.com (b) about.html (c) School news (d) contact.html
  40. 40.📝 How many paragraphs does this code make?
    <p>Good morning!</p>
    <p>Rain today</p>
    <h2>Hello, world!</h2>
    <h2>I love mangoes.</h2>

Answer key

  1. </em>
  2. height
  3. a paragraph
  4. About us
  5. the body
  6. an attribute
  7. </b>
  8. Play games
  9. numbers
  10. src
  11. an empty tag
  12. Match report
  13. 4
  14. True
  15. 4
  16. False
  17. a slash /
  18. a line across the page
  19. False
  20. a closing tag
  21. True
  22. in a new tab
  23. <html>
  24. False
  25. No
  26. an opening tag
  27. on the browser tab
  28. <h1>
  29. <h6>
  30. Our school trip
  31. <li>
  32. cake.jpg
  33. <h6>
  34. <li>
  35. False
  36. saves our .html files
  37. No
  38. an opening tag
  39. about.html
  40. 2

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