← HTML basics test lesson New set →

HTML Worksheet: Practice Test

HTML and CSS lesson 10: HTML basics test · Set 833 · 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.🧩 An opening tag + content + a closing tag together make an ___. (a) attribute (b) editor (c) element (d) address
  2. 2.🏷️ Which is the closing tag for <u>? (a) </u> (b) <u/> (c) <\u> (d) <u>
  3. 3.🔤 In “HTML”, what does the L stand for? (a) Link (b) Line (c) Laptop (d) Language
  4. 4.💬 Which text will NOT show on the page?
    <!-- <p>I love mangoes.</p> -->
    <p>Good morning!</p>
    <p>Hello, world!</p>
    <p>Fun facts</p>
    (a) Fun facts (b) I love mangoes. (c) Hello, world! (d) Good morning!
  5. 5.🔠 How many headings are in this code?
    <h1>Hello, world!</h1>
    <h2>Fun facts</h2>
    <p>Cricket is fun.</p>
    <p>The red kite</p>
  6. 6.🔗 Which address opens when you click this link?
    <a href="news.html">Play games</a>
    (a) Play games (b) news.html (c) games.html (d) quiz.html
  7. 7.🏷️ Which is the closing tag for <i>? (a) <\i> (b) <i/> (c) </i> (d) <i>
  8. 8.📋 Which list tag lists things in any order? (a) <ol> (b) <ul> (c) <li>
  9. 9.🏷️ What does a closing tag have that an opening tag does not? (a) a hash # (b) a slash / (c) a dollar $ (d) a dot .
  10. 10.💬 Which text will NOT show on the page?
    <p>The red kite</p>
    <p>My best friend</p>
    <!-- <p>I love mangoes.</p> -->
    (a) The red kite (b) My best friend (c) I love mangoes.
  11. 11.🔠 Which heading shows the BIGGEST text: <h3>, <h1>, <h6> or <h5>? (a) <h6> (b) <h5> (c) <h3> (d) <h1>
  12. 12.🏷️ Which is the closing tag for <h2>? (a) </h2> (b) <\h2> (c) <h2/> (d) <h2>
  13. 13.🖼️ Does <img> need a closing tag? (a) Yes (b) No
  14. 14.🔠 How many headings are in this code?
    <h1>Fun facts</h1>
    <p>I love mangoes.</p>
    <p>Hello, world!</p>
    <p>Good morning!</p>
  15. 15.🔍 Which line is missing its closing tag?
    line 1: <p>Hello, world!</p>
    line 2: <em>Cricket is fun.</em>
    line 3: <i>I love mangoes.
    (a) line 1 (b) line 2 (c) line 3
  16. 16.🔍 Which line is missing its closing tag?
    line 1: <b>I love mangoes.</b>
    line 2: <strong>Rain today
    line 3: <h2>Cricket is fun.</h2>
    (a) line 3 (b) line 2 (c) line 1
  17. 17.Which of these is true of a code editor? (a) answers page requests (b) has an address bar (c) saves our .html files (d) stores a website’s files
  18. 18.📋 Which list shows the steps of a recipe best? (a) <ul> (b) <hr> (c) <ol> (d) <br>
  19. 19.📝 On how many lines does the browser show this paragraph?
    <p>Kites fly high<br>Stars shine<br>Roses are red<br>Rivers flow<br>Birds sing</p>
  20. 20.📝 On how many lines does the browser show this paragraph?
    <p>Sky is blue<br>Birds sing<br>Stars shine</p>
  21. 21.🖼️ Which picture file does the browser load?
    <img src="moon.png" alt="The full moon" width="150">
    (a) The full moon (b) bus.jpg (c) fort.jpg (d) moon.png
  22. 22.🔗 Which words do you click on?
    <a href="games.html">Take the quiz</a>
    (a) href (b) Play games (c) Take the quiz (d) games.html
  23. 23.True or false: <ul> goes in the head. (a) True (b) False
  24. 24.💬 How many paragraphs show on the page?
    <p>Rain today</p>
    <p>My pets</p>
    <!-- <p>I love mangoes.</p> -->
    <p>The red kite</p>
    <!-- <p>Hello, world!</p> -->
  25. 25.📝 How many paragraphs does this code make?
    <p>Hello, world!</p>
    <p>My pets</p>
    <h2>My best friend</h2>
    <h2>Our school trip</h2>
  26. 26.🖼️ Which picture file does the browser load?
    <img src="dog.jpg" alt="A happy dog" width="400">
    (a) A happy dog (b) dog.jpg (c) bus.jpg (d) moon.png
  27. 27.Which of these has a closing tag? (a) <meta> (b) <br> (c) <hr> (d) <h1>
  28. 28.📝 Does <hr> have a closing tag, or is it an empty tag? (a) an empty tag (b) has a closing tag
  29. 29.Which of these is true of a web browser? (a) sends pages over the net (b) opens web pages for us (c) colours code to help us (d) is where we type code
  30. 30.True or false: a web browser has an address bar. (a) False (b) True
  31. 31.📋 Which list tag is an ordered list? (a) <ul> (b) <ol> (c) <li>
  32. 32.💬 Does the browser show comments on the page? (a) Yes (b) No
  33. 33.🔠 Which heading shows the BIGGEST text: <h4>, <h2>, <h3> or <h1>? (a) <h4> (b) <h2> (c) <h1> (d) <h3>
  34. 34.🔗 Which code links to about.html? (a) <link about.html> (b) <a href="about.html"> (c) <a src="about.html"> (d) <a alt="about.html">
  35. 35.🔗 Which words do you click on?
    <a href="quiz.html">Play games</a>
    (a) About us (b) Play games (c) quiz.html (d) href
  36. 36.💾 A web page file usually ends with which extension? (a) .png (b) .html (c) .mp3 (d) .txt
  37. 37.📝 On how many lines does the browser show this paragraph?
    <p>Sky is blue<br>Kites fly high<br>Birds sing</p>
  38. 38.💬 Which text will NOT show on the page?
    <p>Hello, world!</p>
    <p>I love mangoes.</p>
    <p>My pets</p>
    <!-- <p>Good morning!</p> -->
    (a) I love mangoes. (b) Good morning! (c) My pets (d) Hello, world!
  39. 39.💬 How many paragraphs show on the page?
    <!-- <p>Our school trip</p> -->
    <p>Fun facts</p>
    <p>My best friend</p>
  40. 40.True or false: HTML on its own cannot run a game loop. (a) True (b) False

Answer key

  1. element
  2. </u>
  3. Language
  4. I love mangoes.
  5. 2
  6. news.html
  7. </i>
  8. <ul>
  9. a slash /
  10. I love mangoes.
  11. <h1>
  12. </h2>
  13. No
  14. 1
  15. line 3
  16. line 2
  17. saves our .html files
  18. <ol>
  19. 5
  20. 3
  21. moon.png
  22. Take the quiz
  23. False
  24. 3
  25. 2
  26. dog.jpg
  27. <h1>
  28. an empty tag
  29. opens web pages for us
  30. True
  31. <ol>
  32. No
  33. <h1>
  34. <a href="about.html">
  35. Play games
  36. .html
  37. 3
  38. Good morning!
  39. 2
  40. True

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