← HTML basics test lesson New set →

HTML Worksheet: Practice Test

HTML and CSS lesson 10: HTML basics test · Set 441 · 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 <p> make? (a) a table (b) a link (c) a paragraph (d) a picture
  2. 2.🖼️ Which tag puts a picture on a page? (a) <pic> (b) <p> (c) <a> (d) <img>
  3. 3.💬 Can anyone read your comments by viewing the page source? (a) No (b) Yes
  4. 4.🖼️ Does <img> need a closing tag? (a) No (b) Yes
  5. 5.💬 How does an HTML comment start? (a) <!-- (b) # (c) /* (d) //
  6. 6.📄 What is the first line of an HTML5 page? (a) <html> (b) <body> (c) <head> (d) <!DOCTYPE html>
  7. 7.📄 What is the big heading shown on this page?
    <!DOCTYPE html>
    <html>
    <head>
      <title>Art Gallery</title>
    </head>
    <body>
      <h1>My drawings</h1>
      <p>I like to read.</p>
    </body>
    </html>
    (a) Art Gallery (b) I like to read. (c) body (d) My drawings
  8. 8.📋 Does this list show bullets or numbers?
    <ol>
      <li>Papaya</li>
      <li>Banana</li>
    </ol>
    (a) numbers (b) bullets
  9. 9.🔗 Which address opens when you click this link?
    <a href="art.html">About us</a>
    (a) quiz.html (b) art.html (c) About us (d) news.html
  10. 10.🔠 Which heading shows the BIGGEST text: <h1>, <h4>, <h2> or <h5>? (a) <h1> (b) <h5> (c) <h4> (d) <h2>
  11. 11.💬 Which text will NOT show on the page?
    <!-- <p>Good morning!</p> -->
    <p>Rain today</p>
    <p>Fun facts</p>
    <p>The red kite</p>
    (a) Rain today (b) Fun facts (c) The red kite (d) Good morning!
  12. 12.True or false: <li> is one item of a list. (a) True (b) False
  13. 13.📋 Which list tag goes inside ul or ol? (a) <li> (b) <ol> (c) <ul>
  14. 14.💬 Which text will NOT show on the page?
    <p>My pets</p>
    <!-- <p>My best friend</p> -->
    <p>I love mangoes.</p>
    <p>Rain today</p>
    (a) My pets (b) Rain today (c) I love mangoes. (d) My best friend
  15. 15.Which of these is a closing tag? (a) <li> (b) </p> (c) <body> (d) <title>
  16. 16.True or false: a web browser sends pages over the net. (a) False (b) True
  17. 17.🔠 Which heading shows the SMALLEST text: <h4>, <h1>, <h3> or <h2>? (a) <h3> (b) <h1> (c) <h2> (d) <h4>
  18. 18.🖼️ Which attribute of <img> shows if the image fails? (a) width (b) height (c) src (d) alt
  19. 19.📝 On how many lines does the browser show this paragraph?
    <p>Birds sing<br>Stars shine</p>
  20. 20.📄 Where does <ul> go: in the head or in the body? (a) in the head (b) in the body
  21. 21.🔠 Which heading shows the BIGGEST text: <h1>, <h5>, <h6> or <h2>? (a) <h2> (b) <h6> (c) <h5> (d) <h1>
  22. 22.💬 How many paragraphs show on the page?
    <!-- <p>Hello, world!</p> -->
    <!-- <p>The red kite</p> -->
    <p>Good morning!</p>
    <!-- <p>Our school trip</p> -->
  23. 23.🔗 Which words do you click on?
    <a href="news.html">Visit the site</a>
    (a) Visit the site (b) href (c) news.html (d) Maths fun
  24. 24.Which of these is an opening tag? (a) </b> (b) </h1> (c) </li> (d) <h1>
  25. 25.📋 How many items does this list show?
    <ol>
      <li>Jamun</li>
      <li>Guava</li>
      <li>Orange</li>
      <li>Mango</li>
      <li>Banana</li>
    </ol>
  26. 26.🌐 Which one has an address bar? (a) a code editor (b) a web browser (c) a web server
  27. 27.💬 Which text will NOT show on the page?
    <!-- <p>Good morning!</p> -->
    <p>Fun facts</p>
    <p>My pets</p>
    (a) Good morning! (b) My pets (c) Fun facts
  28. 28.📝 What does <br> do? (a) adds a picture (b) makes a list (c) makes text bold (d) starts a new line
  29. 29.💬 How many paragraphs show on the page?
    <!-- <p>Our school trip</p> -->
    <p>Fun facts</p>
    <p>Hello, world!</p>
  30. 30.🔗 Where does this link open?
    <a href="https://example.com" target="_blank">Maths fun</a>
    (a) in a new tab (b) in the same tab
  31. 31.📋 Which list shows the steps of a recipe best? (a) <hr> (b) <br> (c) <ul> (d) <ol>
  32. 32.🔤 In “HTML”, what do the letters HT stand for? (a) Home Text (b) Hot Tags (c) HyperText (d) High Tech
  33. 33.🖼️ How many pixels wide is the picture drawn?
    <img src="cake.jpg" alt="Birthday cake" width="300">
  34. 34.💬 Which text will NOT show on the page?
    <p>The red kite</p>
    <!-- <p>Hello, world!</p> -->
    <p>I love mangoes.</p>
    <p>Cricket is fun.</p>
    (a) Hello, world! (b) Cricket is fun. (c) The red kite (d) I love mangoes.
  35. 35.Which of these has a closing tag? (a) <title> (b) <input> (c) <br> (d) <meta>
  36. 36.📝 What does <hr> draw? (a) a picture (b) a table (c) a link (d) a line across the page
  37. 37.🔍 One closing tag is missing. Which one?
    <h1>My pets</h1>
    <em>Cricket is fun.
    <strong>The red kite</strong>
    (a) </h2> (b) </h1> (c) </strong> (d) </em>
  38. 38.💬 How does an HTML comment end? (a) --> (b) // (c) >> (d) */
  39. 39.📋 Which tag goes around each item of a list? (a) <ol> (b) <p> (c) <li> (d) <ul>
  40. 40.🔗 Which words do you click on?
    <a href="maths.html">Visit the site</a>
    (a) Maths fun (b) href (c) maths.html (d) Visit the site

Answer key

  1. a paragraph
  2. <img>
  3. Yes
  4. No
  5. <!--
  6. <!DOCTYPE html>
  7. My drawings
  8. numbers
  9. art.html
  10. <h1>
  11. Good morning!
  12. True
  13. <li>
  14. My best friend
  15. </p>
  16. False
  17. <h4>
  18. alt
  19. 2
  20. in the body
  21. <h1>
  22. 1
  23. Visit the site
  24. <h1>
  25. 5
  26. a web browser
  27. Good morning!
  28. starts a new line
  29. 2
  30. in a new tab
  31. <ol>
  32. HyperText
  33. 300
  34. Hello, world!
  35. <title>
  36. a line across the page
  37. </em>
  38. -->
  39. <li>
  40. Visit the site

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