← HTML basics test lesson New set →

HTML Worksheet: Practice Test

HTML and CSS lesson 10: HTML basics test · Set 235 · 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 many paragraphs show on the page?
    <!-- <p>Rain today</p> -->
    <!-- <p>Good morning!</p> -->
    <p>Cricket is fun.</p>
    <p>The red kite</p>
    <!-- <p>My best friend</p> -->
  2. 2.🖼️ The picture cannot load. Which text does the browser show instead?
    <img src="kite.png" alt="A red kite" width="100">
    (a) width (b) Map of India (c) A red kite (d) kite.png
  3. 3.📝 What does <br> do? (a) starts a new line (b) makes a list (c) makes text bold (d) adds a picture
  4. 4.Which of these is true of a code editor? (a) hosts websites online (b) opens web pages for us (c) is where we type code (d) answers page requests
  5. 5.🔍 Which line is missing its closing tag?
    line 1: <em>My best friend</em>
    line 2: <p>The red kite
    line 3: <small>Rain today</small>
    (a) line 2 (b) line 1 (c) line 3
  6. 6.Which of these is a closing tag? (a) <p> (b) <li> (c) <h1> (d) </body>
  7. 7.💬 Does the browser show comments on the page? (a) Yes (b) No
  8. 8.💬 How many paragraphs show on the page?
    <p>The red kite</p>
    <p>My pets</p>
    <!-- <p>Our school trip</p> -->
    <!-- <p>Rain today</p> -->
    <p>Cricket is fun.</p>
  9. 9.🔍 Which line is missing its closing tag?
    line 1: <h3>My pets</h3>
    line 2: <em>Rain today</em>
    line 3: <i>My best friend
    (a) line 3 (b) line 1 (c) line 2
  10. 10.🔗 Which address opens when you click this link?
    <a href="news.html">Take the quiz</a>
    (a) Take the quiz (b) games.html (c) quiz.html (d) news.html
  11. 11.📋 Which list suits a shopping list in any order? (a) <ul> (b) <br> (c) <ol> (d) <hr>
  12. 12.🏷️ Is </h1> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
  13. 13.🔢 In a basic web page file, which comes first: “</html>” or “<!DOCTYPE html>”? (a) </html> (b) <!DOCTYPE html>
  14. 14.True or false: <p> has a closing tag. (a) False (b) True
  15. 15.📋 Which list tag is an unordered list? (a) <ol> (b) <ul> (c) <li>
  16. 16.🔗 Which address opens when you click this link?
    <a href="maths.html">About us</a>
    (a) news.html (b) art.html (c) About us (d) maths.html
  17. 17.🏷️ Which is the closing tag for <i>? (a) <i/> (b) <\i> (c) <i> (d) </i>
  18. 18.Which of these is true of a code editor? (a) answers page requests (b) saves our .html files (c) stores a website’s files (d) shows pages from the web
  19. 19.🖼️ Why do we add alt text to an image? (a) to describe the image (b) to make it bigger (c) to load it faster (d) to colour it
  20. 20.🔢 In a basic web page file, which comes first: “</head>” or “<html>”? (a) </head> (b) <html>
  21. 21.True or false: HTML on its own cannot make links to pages. (a) True (b) False
  22. 22.📋 What number does the browser show next to “Banana”?
    <ol>
      <li>Orange</li>
      <li>Banana</li>
      <li>Grapes</li>
    </ol>
  23. 23.🔠 Which tag is the least important heading? (a) <h1> (b) <h3> (c) <p> (d) <h6>
  24. 24.Which of these is an opening tag? (a) </p> (b) </h1> (c) </li> (d) <h1>
  25. 25.🖼️ Does <img> need a closing tag? (a) Yes (b) No
  26. 26.🔍 Which is the odd one out? (a) turns HTML into a page (b) has an address bar (c) is where we type code (d) opens web pages for us
  27. 27.📄 Can HTML on its own keep a high score? (a) No (b) Yes
  28. 28.🔗 Where does this link open?
    <a href="maths.html" target="_blank">Play games</a>
    (a) in a new tab (b) in the same tab
  29. 29.🔍 Which is the odd one out? (a) is where we type code (b) opens web pages for us (c) saves our .html files (d) shows line numbers
  30. 30.🧩 An opening tag + content + a closing tag together make an ___. (a) address (b) attribute (c) element (d) editor
  31. 31.💬 Can anyone read your comments by viewing the page source? (a) No (b) Yes
  32. 32.True or false: HTML on its own cannot make bullet lists. (a) False (b) True
  33. 33.🏷️ Is <b> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
  34. 34.🏷️ HTML marks up text using ___. (a) wires (b) keys (c) tags (d) pixels
  35. 35.🔗 Which words do you click on?
    <a href="games.html">School news</a>
    (a) href (b) Take the quiz (c) games.html (d) School news
  36. 36.🖼️ How many pixels wide is the picture drawn?
    <img src="tiger.jpg" alt="A tiger asleep" width="200">
  37. 37.💬 Which text will NOT show on the page?
    <p>Hello, world!</p>
    <p>Fun facts</p>
    <p>My best friend</p>
    <!-- <p>My pets</p> -->
    (a) Hello, world! (b) My pets (c) Fun facts (d) My best friend
  38. 38.📝 Does <h1> have a closing tag, or is it an empty tag? (a) has a closing tag (b) an empty tag
  39. 39.📋 Which list tag goes inside ul or ol? (a) <li> (b) <ul> (c) <ol>
  40. 40.True or false: <li> is an empty tag. (a) True (b) False

Answer key

  1. 2
  2. A red kite
  3. starts a new line
  4. is where we type code
  5. line 2
  6. </body>
  7. No
  8. 3
  9. line 3
  10. news.html
  11. <ul>
  12. a closing tag
  13. <!DOCTYPE html>
  14. True
  15. <ul>
  16. maths.html
  17. </i>
  18. saves our .html files
  19. to describe the image
  20. <html>
  21. False
  22. 2
  23. <h6>
  24. <h1>
  25. No
  26. is where we type code
  27. No
  28. in a new tab
  29. opens web pages for us
  30. element
  31. Yes
  32. False
  33. an opening tag
  34. tags
  35. School news
  36. 200
  37. My pets
  38. has a closing tag
  39. <li>
  40. False

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