← HTML basics test lesson New set →

HTML Worksheet: Practice Test

HTML and CSS lesson 10: HTML basics test · Set 873 · 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.🔗 Where does this link open?
    <a href="maths.html" target="_blank">Maths fun</a>
    (a) in a new tab (b) in the same tab
  2. 2.📄 Can HTML on its own show paragraphs? (a) Yes (b) No
  3. 3.🔠 Are headings shown in bold by default? (a) Yes (b) No
  4. 4.🌍 Which program shows a web page to us? (a) a music player (b) a web browser (c) a paint program (d) a calculator
  5. 5.📝 What does <hr> draw? (a) a link (b) a picture (c) a line across the page (d) a table
  6. 6.🔗 Which code links to about.html? (a) <link about.html> (b) <a src="about.html"> (c) <a href="about.html"> (d) <a alt="about.html">
  7. 7.💬 Does the browser show comments on the page? (a) No (b) Yes
  8. 8.🔗 Which tag makes a clickable link? (a) <a> (b) <p> (c) <img> (d) <link>
  9. 9.🌐 Which one saves our .html files? (a) a web server (b) a code editor (c) a web browser
  10. 10.📝 You type 5 spaces between two words in a <p>. How does the browser show them? (a) as 5 spaces (b) as one space (c) as a dot (d) as a new line
  11. 11.🏷️ HTML marks up text using ___. (a) keys (b) pixels (c) tags (d) wires
  12. 12.📝 On how many lines does the browser show this paragraph?
    <p>Sky is blue<br>Stars shine</p>
  13. 13.🏷️ Which is the closing tag for <small>? (a) <\small> (b) </small> (c) <small> (d) <small/>
  14. 14.🖼️ Which picture file does the browser load?
    <img src="tiger.jpg" alt="A tiger asleep" width="400">
    (a) map.png (b) tiger.jpg (c) A tiger asleep (d) kite.png
  15. 15.True or false: <ul> shows 1, 2, 3 numbers. (a) False (b) True
  16. 16.💬 Can anyone read your comments by viewing the page source? (a) No (b) Yes
  17. 17.True or false: HTML on its own can make links to pages. (a) True (b) False
  18. 18.📄 Where does <h1> go: in the head or in the body? (a) in the head (b) in the body
  19. 19.🔍 One closing tag is missing. Which one?
    <u>Fun facts</u>
    <b>My best friend
    <h3>I love mangoes.</h3>
    (a) </u> (b) </b> (c) </h3> (d) </h2>
  20. 20.💬 How many paragraphs show on the page?
    <!-- <p>Good morning!</p> -->
    <!-- <p>Cricket is fun.</p> -->
    <!-- <p>My best friend</p> -->
    <!-- <p>The red kite</p> -->
    <p>Our school trip</p>
  21. 21.💬 Which text will NOT show on the page?
    <p>I love mangoes.</p>
    <p>Hello, world!</p>
    <!-- <p>The red kite</p> -->
    <p>Rain today</p>
    (a) I love mangoes. (b) The red kite (c) Hello, world! (d) Rain today
  22. 22.📋 What number does the browser show next to “Grapes”?
    <ol>
      <li>Litchi</li>
      <li>Grapes</li>
      <li>Guava</li>
      <li>Papaya</li>
      <li>Orange</li>
      <li>Banana</li>
    </ol>
  23. 23.🔠 Which heading shows the BIGGEST text: <h1>, <h5>, <h6> or <h2>? (a) <h5> (b) <h6> (c) <h1> (d) <h2>
  24. 24.True or false: <p> has a closing tag. (a) False (b) True
  25. 25.📋 Which list tag is an ordered list? (a) <ul> (b) <li> (c) <ol>
  26. 26.🔍 Which is the odd one out? (a) colours code to help us (b) shows line numbers (c) answers page requests (d) is where we type code
  27. 27.📋 How many items does this list show?
    <ol>
      <li>Mango</li>
      <li>Banana</li>
      <li>Litchi</li>
      <li>Guava</li>
      <li>Jamun</li>
      <li>Orange</li>
    </ol>
  28. 28.True or false: <input> has a closing tag. (a) True (b) False
  29. 29.🔍 One closing tag is missing. Which one?
    <em>I love mangoes.</em>
    <b>Fun facts
    <i>Our school trip</i>
    (a) </u> (b) </i> (c) </em> (d) </b>
  30. 30.🔠 Which heading shows the SMALLEST text: <h1>, <h3>, <h5> or <h4>? (a) <h3> (b) <h1> (c) <h5> (d) <h4>
  31. 31.🏷️ Is <p> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
  32. 32.Which of these has a closing tag? (a) <img> (b) <hr> (c) <br> (d) <p>
  33. 33.🔤 In “HTML”, what does the L stand for? (a) Line (b) Language (c) Laptop (d) Link
  34. 34.📄 Can HTML on its own pick a random number? (a) No (b) Yes
  35. 35.🔗 What does target="_blank" do to a link? (a) hides the link (b) makes it blank (c) makes it bold (d) opens it in a new tab
  36. 36.💬 How many paragraphs show on the page?
    <!-- <p>My pets</p> -->
    <!-- <p>Cricket is fun.</p> -->
    <p>My best friend</p>
    <p>Our school trip</p>
  37. 37.🔍 One closing tag is missing. Which one?
    <p>Our school trip</p>
    <b>My best friend</b>
    <h3>My pets
    (a) </p> (b) </h3> (c) </b> (d) </u>
  38. 38.📝 How many paragraphs does this code make?
    <p>My best friend</p>
    <h2>My pets</h2>
    <p>Rain today</p>
  39. 39.📝 Does <b> have a closing tag, or is it an empty tag? (a) has a closing tag (b) an empty tag
  40. 40.📝 Does <meta> have a closing tag, or is it an empty tag? (a) an empty tag (b) has a closing tag

Answer key

  1. in a new tab
  2. Yes
  3. Yes
  4. a web browser
  5. a line across the page
  6. <a href="about.html">
  7. No
  8. <a>
  9. a code editor
  10. as one space
  11. tags
  12. 2
  13. </small>
  14. tiger.jpg
  15. False
  16. Yes
  17. True
  18. in the body
  19. </b>
  20. 1
  21. The red kite
  22. 2
  23. <h1>
  24. True
  25. <ol>
  26. answers page requests
  27. 6
  28. False
  29. </b>
  30. <h5>
  31. an opening tag
  32. <p>
  33. Language
  34. No
  35. opens it in a new tab
  36. 2
  37. </h3>
  38. 2
  39. has a closing tag
  40. an empty tag

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