← HTML basics test lesson New set →

HTML Worksheet: Practice Test

HTML and CSS lesson 10: HTML basics test · Set 495 · 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>My pets</p>
    <!-- <p>I love mangoes.</p> -->
    <!-- <p>Good morning!</p> -->
  2. 2.🔠 Which heading shows the SMALLEST text: <h1>, <h6>, <h3> or <h4>? (a) <h4> (b) <h1> (c) <h3> (d) <h6>
  3. 3.🔗 Which code links to about.html? (a) <a alt="about.html"> (b) <a href="about.html"> (c) <link about.html> (d) <a src="about.html">
  4. 4.📄 What is the big heading shown on this page?
    <!DOCTYPE html>
    <html>
    <head>
      <title>Riya’s Recipes</title>
    </head>
    <body>
      <h1>My drawings</h1>
      <p>Thanks for visiting.</p>
    </body>
    </html>
    (a) Thanks for visiting. (b) My drawings (c) Riya’s Recipes (d) body
  5. 5.🔗 What does target="_blank" do to a link? (a) hides the link (b) makes it bold (c) opens it in a new tab (d) makes it blank
  6. 6.🔠 Which tag is the least important heading? (a) <p> (b) <h3> (c) <h6> (d) <h1>
  7. 7.🔍 Which line is missing its closing tag?
    line 1: <u>Cricket is fun.</u>
    line 2: <b>My pets</b>
    line 3: <i>The red kite
    (a) line 2 (b) line 1 (c) line 3
  8. 8.🔗 Which words do you click on?
    <a href="about.html">Take the quiz</a>
    (a) Play games (b) about.html (c) Take the quiz (d) href
  9. 9.🔗 Which address opens when you click this link?
    <a href="maths.html">Art corner</a>
    (a) news.html (b) Art corner (c) maths.html (d) art.html
  10. 10.Which of these has a closing tag? (a) <title> (b) <meta> (c) <img> (d) <br>
  11. 11.📄 What does the browser tab show for this page?
    <!DOCTYPE html>
    <html>
    <head>
      <title>Cricket Club</title>
    </head>
    <body>
      <h1>Welcome!</h1>
      <p>Try this poha.</p>
    </body>
    </html>
    (a) Welcome! (b) index.html (c) Try this poha. (d) Cricket Club
  12. 12.💬 How many paragraphs show on the page?
    <p>Our school trip</p>
    <!-- <p>Cricket is fun.</p> -->
    <!-- <p>Hello, world!</p> -->
  13. 13.Which of these is true of a web browser? (a) saves our .html files (b) colours code to help us (c) sends pages over the net (d) shows pages from the web
  14. 14.🔠 Which heading shows the BIGGEST text: <h4>, <h1>, <h3> or <h2>? (a) <h3> (b) <h2> (c) <h4> (d) <h1>
  15. 15.🔠 Which heading shows the BIGGEST text: <h3>, <h4>, <h6> or <h5>? (a) <h6> (b) <h3> (c) <h4> (d) <h5>
  16. 16.📝 What does <br> do? (a) makes a list (b) starts a new line (c) makes text bold (d) adds a picture
  17. 17.🔗 Which attribute holds the address of a link? (a) src (b) alt (c) id (d) href
  18. 18.💬 Which text will NOT show on the page?
    <p>My best friend</p>
    <p>Good morning!</p>
    <p>I love mangoes.</p>
    <!-- <p>The red kite</p> -->
    (a) My best friend (b) The red kite (c) Good morning! (d) I love mangoes.
  19. 19.💬 How many paragraphs show on the page?
    <p>Rain today</p>
    <!-- <p>My pets</p> -->
    <p>Hello, world!</p>
  20. 20.💬 How does an HTML comment end? (a) // (b) >> (c) */ (d) -->
  21. 21.Which of these is a closing tag? (a) <h1> (b) <p> (c) <title> (d) </p>
  22. 22.🏷️ Is <b> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
  23. 23.🌐 Which one hosts websites online? (a) a code editor (b) a web browser (c) a web server
  24. 24.📄 What is the big heading shown on this page?
    <!DOCTYPE html>
    <html>
    <head>
      <title>Riya’s Recipes</title>
    </head>
    <body>
      <h1>All about me</h1>
      <p>I like to read.</p>
    </body>
    </html>
    (a) body (b) I like to read. (c) All about me (d) Riya’s Recipes
  25. 25.Which of these has a closing tag? (a) <img> (b) <input> (c) <hr> (d) <ul>
  26. 26.📋 How many items does this list show?
    <ul>
      <li>Papaya</li>
      <li>Jamun</li>
      <li>Orange</li>
    </ul>
  27. 27.True or false: in <img>, alt describes the picture. (a) True (b) False
  28. 28.📄 Can HTML on its own keep a high score? (a) No (b) Yes
  29. 29.📝 What does <p> make? (a) a picture (b) a table (c) a link (d) a paragraph
  30. 30.📛 In <a href="x.html">, what is href? (a) an attribute (b) an element name (c) a comment (d) a closing tag
  31. 31.📄 Where does <a> go: in the head or in the body? (a) in the body (b) in the head
  32. 32.📄 Can HTML on its own add pictures to a page? (a) Yes (b) No
  33. 33.💬 Why do coders write comments? (a) to show pictures (b) to leave notes (c) to make links (d) to add colour
  34. 34.🔠 Which heading shows the SMALLEST text: <h1>, <h5>, <h2> or <h4>? (a) <h1> (b) <h5> (c) <h2> (d) <h4>
  35. 35.🔠 Which heading shows the BIGGEST text: <h3>, <h4>, <h1> or <h2>? (a) <h4> (b) <h3> (c) <h1> (d) <h2>
  36. 36.🔠 Which heading shows the BIGGEST text: <h2>, <h4>, <h3> or <h1>? (a) <h3> (b) <h4> (c) <h1> (d) <h2>
  37. 37.🏷️ Every HTML tag starts with which sign? (a) < (b) { (c) [ (d) (
  38. 38.💬 Can anyone read your comments by viewing the page source? (a) Yes (b) No
  39. 39.📝 On how many lines does the browser show this paragraph?
    <p>Kites fly high<br>Stars shine<br>Roses are red<br>Birds sing<br>Rivers flow</p>
  40. 40.🔍 Which is the odd one out? (a) turns HTML into a page (b) shows pages from the web (c) has an address bar (d) is where we type code

Answer key

  1. 1
  2. <h6>
  3. <a href="about.html">
  4. My drawings
  5. opens it in a new tab
  6. <h6>
  7. line 3
  8. Take the quiz
  9. maths.html
  10. <title>
  11. Cricket Club
  12. 1
  13. shows pages from the web
  14. <h1>
  15. <h3>
  16. starts a new line
  17. href
  18. The red kite
  19. 2
  20. -->
  21. </p>
  22. an opening tag
  23. a web server
  24. All about me
  25. <ul>
  26. 3
  27. True
  28. No
  29. a paragraph
  30. an attribute
  31. in the body
  32. Yes
  33. to leave notes
  34. <h5>
  35. <h1>
  36. <h1>
  37. <
  38. Yes
  39. 5
  40. is where we type code

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