← HTML comments lesson New set →

HTML Worksheet: Comments

HTML and CSS lesson 9: HTML comments · Set 743 · 40 questions
TalentJR

Code tip (Hidden notes): A comment is <!-- note -->: it starts with <!-- and ends with -->. Anything inside a comment, even a whole <p>, is not shown. Comments can be read with “view source” — never put secrets in them.

NameDateTime takenScore ___ / 40
  1. 1.💬 Which text will NOT show on the page?
    <p>I love mangoes.</p>
    <!-- <p>Our school trip</p> -->
    <p>Good morning!</p>
    <p>Fun facts</p>
    (a) Fun facts (b) I love mangoes. (c) Good morning! (d) Our school trip
  2. 2.💬 Which text will NOT show on the page?
    <p>I love mangoes.</p>
    <p>Cricket is fun.</p>
    <!-- <p>Good morning!</p> -->
    (a) I love mangoes. (b) Good morning! (c) Cricket is fun.
  3. 3.💬 How many paragraphs show on the page?
    <p>Fun facts</p>
    <!-- <p>Our school trip</p> -->
    <!-- <p>Hello, world!</p> -->
    <!-- <p>My pets</p> -->
  4. 4.💬 How does an HTML comment end? (a) >> (b) --> (c) */ (d) //
  5. 5.💬 Which text will NOT show on the page?
    <p>The red kite</p>
    <p>My pets</p>
    <p>My best friend</p>
    <!-- <p>Rain today</p> -->
    (a) My pets (b) My best friend (c) Rain today (d) The red kite
  6. 6.💬 Which text will NOT show on the page?
    <p>My pets</p>
    <p>The red kite</p>
    <!-- <p>Good morning!</p> -->
    <p>Hello, world!</p>
    (a) The red kite (b) Hello, world! (c) Good morning! (d) My pets
  7. 7.💬 How many paragraphs show on the page?
    <p>Rain today</p>
    <!-- <p>Our school trip</p> -->
    <!-- <p>Cricket is fun.</p> -->
    <!-- <p>Good morning!</p> -->
    <p>My pets</p>
  8. 8.💬 How does an HTML comment start? (a) // (b) /* (c) <!-- (d) #
  9. 9.💬 How many paragraphs show on the page?
    <!-- <p>Fun facts</p> -->
    <p>My best friend</p>
    <p>Cricket is fun.</p>
    <p>My pets</p>
  10. 10.💬 How many paragraphs show on the page?
    <!-- <p>Fun facts</p> -->
    <!-- <p>Our school trip</p> -->
    <p>The red kite</p>
  11. 11.💬 How many paragraphs show on the page?
    <!-- <p>Good morning!</p> -->
    <p>My pets</p>
    <p>My best friend</p>
  12. 12.💬 Does the browser show comments on the page? (a) Yes (b) No
  13. 13.💬 Which text will NOT show on the page?
    <p>The red kite</p>
    <!-- <p>Rain today</p> -->
    <p>Fun facts</p>
    (a) Fun facts (b) Rain today (c) The red kite
  14. 14.💬 Which text will NOT show on the page?
    <!-- <p>My best friend</p> -->
    <p>Our school trip</p>
    <p>My pets</p>
    (a) My best friend (b) My pets (c) Our school trip
  15. 15.💬 Which text will NOT show on the page?
    <!-- <p>Our school trip</p> -->
    <p>Hello, world!</p>
    <p>My pets</p>
    <p>Good morning!</p>
    (a) Hello, world! (b) Good morning! (c) Our school trip (d) My pets
  16. 16.💬 Why do coders write comments? (a) to add colour (b) to show pictures (c) to make links (d) to leave notes
  17. 17.💬 How many paragraphs show on the page?
    <!-- <p>My best friend</p> -->
    <!-- <p>I love mangoes.</p> -->
    <p>My pets</p>
    <p>The red kite</p>
    <!-- <p>Fun facts</p> -->
  18. 18.💬 Which text will NOT show on the page?
    <p>My pets</p>
    <!-- <p>Hello, world!</p> -->
    <p>Good morning!</p>
    (a) Hello, world! (b) My pets (c) Good morning!
  19. 19.💬 Which text will NOT show on the page?
    <p>Rain today</p>
    <p>My pets</p>
    <!-- <p>Cricket is fun.</p> -->
    (a) My pets (b) Rain today (c) Cricket is fun.
  20. 20.💬 How many paragraphs show on the page?
    <p>Cricket is fun.</p>
    <!-- <p>The red kite</p> -->
    <p>Fun facts</p>
    <p>My best friend</p>
  21. 21.💬 How many paragraphs show on the page?
    <p>Hello, world!</p>
    <!-- <p>My pets</p> -->
    <p>I love mangoes.</p>
  22. 22.💬 Which text will NOT show on the page?
    <!-- <p>My best friend</p> -->
    <p>Fun facts</p>
    <p>Our school trip</p>
    (a) My best friend (b) Fun facts (c) Our school trip
  23. 23.💬 Which text will NOT show on the page?
    <!-- <p>Cricket is fun.</p> -->
    <p>Fun facts</p>
    <p>My best friend</p>
    (a) Cricket is fun. (b) My best friend (c) Fun facts
  24. 24.💬 Which text will NOT show on the page?
    <p>Good morning!</p>
    <!-- <p>Hello, world!</p> -->
    <p>I love mangoes.</p>
    <p>Fun facts</p>
    (a) I love mangoes. (b) Fun facts (c) Good morning! (d) Hello, world!
  25. 25.💬 Which text will NOT show on the page?
    <!-- <p>Cricket is fun.</p> -->
    <p>Our school trip</p>
    <p>I love mangoes.</p>
    (a) I love mangoes. (b) Our school trip (c) Cricket is fun.
  26. 26.💬 How many paragraphs show on the page?
    <!-- <p>My best friend</p> -->
    <p>Our school trip</p>
    <!-- <p>Fun facts</p> -->
  27. 27.💬 Which text will NOT show on the page?
    <p>My best friend</p>
    <p>Our school trip</p>
    <!-- <p>Good morning!</p> -->
    <p>Cricket is fun.</p>
    (a) My best friend (b) Cricket is fun. (c) Our school trip (d) Good morning!
  28. 28.💬 How many paragraphs show on the page?
    <!-- <p>Our school trip</p> -->
    <p>I love mangoes.</p>
    <p>Hello, world!</p>
  29. 29.💬 How many paragraphs show on the page?
    <p>Good morning!</p>
    <!-- <p>Hello, world!</p> -->
    <!-- <p>Rain today</p> -->
  30. 30.💬 Which text will NOT show on the page?
    <p>My pets</p>
    <!-- <p>I love mangoes.</p> -->
    <p>Cricket is fun.</p>
    (a) My pets (b) Cricket is fun. (c) I love mangoes.
  31. 31.💬 Which text will NOT show on the page?
    <p>Our school trip</p>
    <!-- <p>My best friend</p> -->
    <p>I love mangoes.</p>
    (a) My best friend (b) Our school trip (c) I love mangoes.
  32. 32.💬 How many paragraphs show on the page?
    <p>Hello, world!</p>
    <p>Good morning!</p>
    <!-- <p>I love mangoes.</p> -->
    <p>Our school trip</p>
    <p>The red kite</p>
  33. 33.💬 How many paragraphs show on the page?
    <p>Rain today</p>
    <p>I love mangoes.</p>
    <p>Cricket is fun.</p>
    <p>Good morning!</p>
    <!-- <p>My best friend</p> -->
  34. 34.💬 How many paragraphs show on the page?
    <!-- <p>Cricket is fun.</p> -->
    <p>Hello, world!</p>
    <!-- <p>Rain today</p> -->
  35. 35.💬 Which text will NOT show on the page?
    <!-- <p>I love mangoes.</p> -->
    <p>The red kite</p>
    <p>Our school trip</p>
    <p>Fun facts</p>
    (a) The red kite (b) Our school trip (c) Fun facts (d) I love mangoes.
  36. 36.💬 Which text will NOT show on the page?
    <p>I love mangoes.</p>
    <!-- <p>Fun facts</p> -->
    <p>Cricket is fun.</p>
    (a) Fun facts (b) I love mangoes. (c) Cricket is fun.
  37. 37.💬 How many paragraphs show on the page?
    <!-- <p>I love mangoes.</p> -->
    <p>Hello, world!</p>
    <p>My best friend</p>
  38. 38.💬 Which text will NOT show on the page?
    <p>Our school trip</p>
    <p>Good morning!</p>
    <p>I love mangoes.</p>
    <!-- <p>Hello, world!</p> -->
    (a) Hello, world! (b) Good morning! (c) I love mangoes. (d) Our school trip
  39. 39.💬 How many paragraphs show on the page?
    <p>Rain today</p>
    <!-- <p>Fun facts</p> -->
    <p>My best friend</p>
    <!-- <p>I love mangoes.</p> -->
  40. 40.💬 How many paragraphs show on the page?
    <p>Our school trip</p>
    <p>Rain today</p>
    <p>Hello, world!</p>
    <!-- <p>My pets</p> -->
    <p>Good morning!</p>

Answer key

  1. Our school trip
  2. Good morning!
  3. 1
  4. -->
  5. Rain today
  6. Good morning!
  7. 2
  8. <!--
  9. 3
  10. 1
  11. 2
  12. No
  13. Rain today
  14. My best friend
  15. Our school trip
  16. to leave notes
  17. 2
  18. Hello, world!
  19. Cricket is fun.
  20. 3
  21. 2
  22. My best friend
  23. Cricket is fun.
  24. Hello, world!
  25. Cricket is fun.
  26. 1
  27. Good morning!
  28. 2
  29. 1
  30. I love mangoes.
  31. My best friend
  32. 4
  33. 4
  34. 1
  35. I love mangoes.
  36. Fun facts
  37. 2
  38. Hello, world!
  39. 2
  40. 4

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