← HTML basics test lesson New set →

HTML Worksheet: Practice Test

HTML and CSS lesson 10: HTML basics test · Set 492 · 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.📝 What does <hr> draw? (a) a table (b) a line across the page (c) a picture (d) a link
  2. 2.True or false: HTML on its own cannot add up two numbers. (a) False (b) True
  3. 3.🔗 Which words do you click on?
    <a href="games.html">About us</a>
    (a) href (b) games.html (c) Contact us (d) About us
  4. 4.🔠 Which heading shows the BIGGEST text: <h2>, <h5>, <h3> or <h4>? (a) <h4> (b) <h3> (c) <h2> (d) <h5>
  5. 5.🌐 Which one turns HTML into a page? (a) a web browser (b) a code editor (c) a web server
  6. 6.💬 How does an HTML comment end? (a) */ (b) // (c) >> (d) -->
  7. 7.🔍 Which is the odd one out? (a) shows pages from the web (b) hosts websites online (c) turns HTML into a page (d) opens web pages for us
  8. 8.🧱 HTML gives a web page its ___. (a) speed (b) sound (c) structure (d) colours
  9. 9.🔠 Which tag is the least important heading? (a) <h3> (b) <h1> (c) <p> (d) <h6>
  10. 10.📝 What do we need to write HTML? (a) a paintbrush (b) a printer (c) a microphone (d) a plain text editor
  11. 11.📄 Where does <title> go: in the head or in the body? (a) in the head (b) in the body
  12. 12.Which of these is an empty tag? (a) <li> (b) <b> (c) <title> (d) <meta>
  13. 13.🏷️ Every HTML tag starts with which sign? (a) [ (b) < (c) ( (d) {
  14. 14.True or false: <ol> shows 1, 2, 3 numbers. (a) False (b) True
  15. 15.📝 On how many lines does the browser show this paragraph?
    <p>Stars shine<br>Roses are red<br>Birds sing<br>Kites fly high</p>
  16. 16.🔠 How many headings are in this code?
    <h1>My pets</h1>
    <h2>I love mangoes.</h2>
    <p>I love mangoes.</p>
    <p>My pets</p>
    <p>My pets</p>
  17. 17.🔠 Which heading shows the SMALLEST text: <h6>, <h1>, <h5> or <h4>? (a) <h1> (b) <h4> (c) <h6> (d) <h5>
  18. 18.🔠 How many headings are in this code?
    <h1>Good morning!</h1>
    <h3>My best friend</h3>
    <p>I love mangoes.</p>
  19. 19.💬 How many paragraphs show on the page?
    <!-- <p>I love mangoes.</p> -->
    <!-- <p>Our school trip</p> -->
    <p>The red kite</p>
  20. 20.💬 How many paragraphs show on the page?
    <!-- <p>Hello, world!</p> -->
    <!-- <p>Fun facts</p> -->
    <p>The red kite</p>
    <p>Good morning!</p>
    <!-- <p>I love mangoes.</p> -->
  21. 21.True or false: in <img>, src sets how wide it is. (a) True (b) False
  22. 22.🖼️ How many pixels wide is the picture drawn?
    <img src="fort.jpg" alt="An old fort" width="50">
  23. 23.🔠 How many heading levels does HTML have? (a) 4 (b) 3 (c) 6 (d) 10
  24. 24.🔗 What does target="_blank" do to a link? (a) opens it in a new tab (b) makes it bold (c) hides the link (d) makes it blank
  25. 25.🔍 One closing tag is missing. Which one?
    <b>Our school trip</b>
    <h2>The red kite</h2>
    <strong>Good morning!
    (a) </b> (b) </h2> (c) </u> (d) </strong>
  26. 26.💬 Which text will NOT show on the page?
    <p>My best friend</p>
    <p>My pets</p>
    <!-- <p>Hello, world!</p> -->
    <p>Cricket is fun.</p>
    (a) My pets (b) Cricket is fun. (c) My best friend (d) Hello, world!
  27. 27.Which of these has a closing tag? (a) <li> (b) <br> (c) <hr> (d) <meta>
  28. 28.🔢 In a basic web page file, which comes first: “</head>” or “</body>”? (a) </body> (b) </head>
  29. 29.True or false: <li> is an empty tag. (a) False (b) True
  30. 30.🏷️ Is </h1> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
  31. 31.📝 Does <input> have a closing tag, or is it an empty tag? (a) an empty tag (b) has a closing tag
  32. 32.🔠 Are headings shown in bold by default? (a) No (b) Yes
  33. 33.True or false: <title> goes in the head. (a) True (b) False
  34. 34.🔍 One closing tag is missing. Which one?
    <h2>Rain today</h2>
    <p>Cricket is fun.
    <small>Hello, world!</small>
    (a) </h2> (b) </u> (c) </p> (d) </small>
  35. 35.🔠 How many headings are in this code?
    <h1>Our school trip</h1>
    <p>My best friend</p>
    <p>I love mangoes.</p>
  36. 36.🔢 In a basic web page file, which comes first: “<body>” or “<html>”? (a) <body> (b) <html>
  37. 37.🔍 Which line is missing its closing tag?
    line 1: <small>Hello, world!
    line 2: <u>I love mangoes.</u>
    line 3: <h2>My pets</h2>
    (a) line 2 (b) line 3 (c) line 1
  38. 38.💬 Does the browser show comments on the page? (a) No (b) Yes
  39. 39.🔠 Which heading shows the SMALLEST text: <h3>, <h2>, <h1> or <h6>? (a) <h2> (b) <h6> (c) <h3> (d) <h1>
  40. 40.🔠 Which heading shows the SMALLEST text: <h3>, <h6>, <h4> or <h1>? (a) <h1> (b) <h6> (c) <h3> (d) <h4>

Answer key

  1. a line across the page
  2. True
  3. About us
  4. <h2>
  5. a web browser
  6. -->
  7. hosts websites online
  8. structure
  9. <h6>
  10. a plain text editor
  11. in the head
  12. <meta>
  13. <
  14. True
  15. 4
  16. 2
  17. <h6>
  18. 2
  19. 1
  20. 2
  21. False
  22. 50
  23. 6
  24. opens it in a new tab
  25. </strong>
  26. Hello, world!
  27. <li>
  28. </head>
  29. False
  30. a closing tag
  31. an empty tag
  32. Yes
  33. True
  34. </p>
  35. 1
  36. <html>
  37. line 1
  38. No
  39. <h6>
  40. <h6>

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