← HTML comments lesson New set →

HTML Worksheet: Comments

HTML and CSS lesson 9: HTML comments · Set 86 · 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>Good morning!</p>
    <p>Fun facts</p>
    <!-- <p>My best friend</p> -->
    (a) Good morning! (b) Fun facts (c) My best friend (d) I love mangoes.
  2. 2.💬 Which text will NOT show on the page?
    <p>The red kite</p>
    <!-- <p>I love mangoes.</p> -->
    <p>My best friend</p>
    <p>Our school trip</p>
    (a) Our school trip (b) The red kite (c) I love mangoes. (d) My best friend
  3. 3.💬 How many paragraphs show on the page?
    <p>Rain today</p>
    <!-- <p>Good morning!</p> -->
    <!-- <p>Cricket is fun.</p> -->
  4. 4.💬 How many paragraphs show on the page?
    <p>My best friend</p>
    <!-- <p>Rain today</p> -->
    <!-- <p>My pets</p> -->
  5. 5.💬 Which text will NOT show on the page?
    <p>Hello, world!</p>
    <p>Good morning!</p>
    <!-- <p>My best friend</p> -->
    (a) Hello, world! (b) My best friend (c) Good morning!
  6. 6.💬 How many paragraphs show on the page?
    <p>Fun facts</p>
    <p>Rain today</p>
    <p>Good morning!</p>
    <!-- <p>Hello, world!</p> -->
    <p>Cricket is fun.</p>
  7. 7.💬 Does the browser show comments on the page? (a) No (b) Yes
  8. 8.💬 How does an HTML comment end? (a) >> (b) // (c) --> (d) */
  9. 9.💬 How many paragraphs show on the page?
    <!-- <p>My best friend</p> -->
    <p>Rain today</p>
    <!-- <p>Good morning!</p> -->
    <p>Hello, world!</p>
  10. 10.💬 How many paragraphs show on the page?
    <p>Rain today</p>
    <!-- <p>I love mangoes.</p> -->
    <!-- <p>Hello, world!</p> -->
  11. 11.💬 How many paragraphs show on the page?
    <!-- <p>My best friend</p> -->
    <!-- <p>Rain today</p> -->
    <!-- <p>Good morning!</p> -->
    <p>My pets</p>
  12. 12.💬 Which text will NOT show on the page?
    <!-- <p>Good morning!</p> -->
    <p>Fun facts</p>
    <p>Our school trip</p>
    <p>My pets</p>
    (a) Our school trip (b) Good morning! (c) Fun facts (d) My pets
  13. 13.💬 Can anyone read your comments by viewing the page source? (a) No (b) Yes
  14. 14.💬 Which text will NOT show on the page?
    <p>Cricket is fun.</p>
    <!-- <p>I love mangoes.</p> -->
    <p>Our school trip</p>
    (a) Our school trip (b) Cricket is fun. (c) I love mangoes.
  15. 15.💬 Which text will NOT show on the page?
    <p>My best friend</p>
    <p>My pets</p>
    <!-- <p>Our school trip</p> -->
    <p>Rain today</p>
    (a) Rain today (b) My best friend (c) Our school trip (d) My pets
  16. 16.💬 Which text will NOT show on the page?
    <!-- <p>Cricket is fun.</p> -->
    <p>The red kite</p>
    <p>My pets</p>
    <p>I love mangoes.</p>
    (a) I love mangoes. (b) Cricket is fun. (c) The red kite (d) My pets
  17. 17.💬 Which text will NOT show on the page?
    <p>Cricket is fun.</p>
    <p>Our school trip</p>
    <!-- <p>I love mangoes.</p> -->
    (a) Cricket is fun. (b) Our school trip (c) I love mangoes.
  18. 18.💬 Which text will NOT show on the page?
    <p>I love mangoes.</p>
    <p>Cricket is fun.</p>
    <p>My pets</p>
    <!-- <p>Our school trip</p> -->
    (a) Cricket is fun. (b) My pets (c) Our school trip (d) I love mangoes.
  19. 19.💬 Which text will NOT show on the page?
    <p>My best friend</p>
    <!-- <p>Rain today</p> -->
    <p>The red kite</p>
    (a) The red kite (b) Rain today (c) My best friend
  20. 20.💬 Which text will NOT show on the page?
    <p>Rain today</p>
    <p>Cricket is fun.</p>
    <p>Fun facts</p>
    <!-- <p>Our school trip</p> -->
    (a) Our school trip (b) Rain today (c) Fun facts (d) Cricket is fun.
  21. 21.💬 How many paragraphs show on the page?
    <p>My pets</p>
    <!-- <p>Fun facts</p> -->
    <!-- <p>Hello, world!</p> -->
    <p>Our school trip</p>
  22. 22.💬 Which text will NOT show on the page?
    <p>Good morning!</p>
    <p>My pets</p>
    <!-- <p>Fun facts</p> -->
    <p>Our school trip</p>
    (a) Good morning! (b) My pets (c) Fun facts (d) Our school trip
  23. 23.💬 Which text will NOT show on the page?
    <p>My pets</p>
    <p>Rain today</p>
    <!-- <p>Our school trip</p> -->
    <p>Cricket is fun.</p>
    (a) Rain today (b) Cricket is fun. (c) Our school trip (d) My pets
  24. 24.💬 How many paragraphs show on the page?
    <p>Rain today</p>
    <!-- <p>My best friend</p> -->
    <p>The red kite</p>
    <p>Good morning!</p>
  25. 25.💬 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) Cricket is fun. (c) I love mangoes.
  26. 26.💬 How many paragraphs show on the page?
    <!-- <p>The red kite</p> -->
    <p>My best friend</p>
    <p>Hello, world!</p>
  27. 27.💬 Which text will NOT show on the page?
    <!-- <p>Our school trip</p> -->
    <p>My pets</p>
    <p>Cricket is fun.</p>
    (a) Cricket is fun. (b) My pets (c) Our school trip
  28. 28.💬 How many paragraphs show on the page?
    <!-- <p>My best friend</p> -->
    <p>I love mangoes.</p>
    <p>Rain today</p>
  29. 29.💬 Which text will NOT show on the page?
    <!-- <p>My best friend</p> -->
    <p>I love mangoes.</p>
    <p>My pets</p>
    <p>Hello, world!</p>
    (a) I love mangoes. (b) Hello, world! (c) My pets (d) My best friend
  30. 30.💬 How does an HTML comment start? (a) # (b) // (c) <!-- (d) /*
  31. 31.💬 Which text will NOT show on the page?
    <p>Cricket is fun.</p>
    <p>Hello, world!</p>
    <!-- <p>I love mangoes.</p> -->
    (a) Cricket is fun. (b) I love mangoes. (c) Hello, world!
  32. 32.💬 Which text will NOT show on the page?
    <p>I love mangoes.</p>
    <p>The red kite</p>
    <!-- <p>Hello, world!</p> -->
    <p>Rain today</p>
    (a) I love mangoes. (b) Rain today (c) Hello, world! (d) The red kite
  33. 33.💬 Which text will NOT show on the page?
    <p>My best friend</p>
    <!-- <p>Fun facts</p> -->
    <p>Rain today</p>
    (a) My best friend (b) Rain today (c) Fun facts
  34. 34.💬 Which text will NOT show on the page?
    <p>Good morning!</p>
    <!-- <p>My best friend</p> -->
    <p>Hello, world!</p>
    (a) Hello, world! (b) Good morning! (c) My best friend
  35. 35.💬 How many paragraphs show on the page?
    <!-- <p>Rain today</p> -->
    <p>Our school trip</p>
    <p>Fun facts</p>
    <p>My best friend</p>
    <p>Cricket is fun.</p>
  36. 36.💬 Which text will NOT show on the page?
    <p>Fun facts</p>
    <p>Hello, world!</p>
    <p>My best friend</p>
    <!-- <p>My pets</p> -->
    (a) Hello, world! (b) My pets (c) Fun facts (d) My best friend
  37. 37.💬 How many paragraphs show on the page?
    <!-- <p>I love mangoes.</p> -->
    <!-- <p>Cricket is fun.</p> -->
    <p>Fun facts</p>
  38. 38.💬 How many paragraphs show on the page?
    <!-- <p>Good morning!</p> -->
    <!-- <p>Our school trip</p> -->
    <p>My pets</p>
  39. 39.💬 How many paragraphs show on the page?
    <p>Rain today</p>
    <!-- <p>The red kite</p> -->
    <!-- <p>Good morning!</p> -->
    <!-- <p>I love mangoes.</p> -->
    <p>Hello, world!</p>
  40. 40.💬 How many paragraphs show on the page?
    <!-- <p>Rain today</p> -->
    <!-- <p>The red kite</p> -->
    <p>My best friend</p>
    <!-- <p>My pets</p> -->

Answer key

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

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