← Web development final test lesson New set →

Web Development Worksheet: Final Test

HTML and CSS lesson 30: Web development final test · Set 684 · 40 questions
TalentJR

Code tip (Read it like a browser): Find the topic: HTML, CSS, JavaScript or how the web works. Read the code line by line, the way a browser would. For sums and loops, write each step down and check it again.

NameDateTime takenScore ___ / 40
  1. 1.🔠 Which tag is used for the main title on a page? (a) <p> (b) <br> (c) <h1> (d) <h6>
  2. 2.✍️ Which sign ends each CSS declaration? (a) . (b) ; (c) : (d) ,
  3. 3.🔍 Which is the odd one out? (a) reacts to a button click (b) changes the page live (c) changes the text size (d) counts down a timer
  4. 4.True or false: a web server stores a website’s files. (a) True (b) False
  5. 5.🌍 What is the path in this URL?
    https://www.example.com/about.html
    (a) /maths/tables.html (b) https (c) /about.html (d) www.example.com
  6. 6.True or false: “colour as the only clue” helps everyone use the page. (a) True (b) False
  7. 7.🛡️ Online: is it safe to click prize links? (a) not safe (b) safe
  8. 8.🚀 What is the home page file of a website usually called? (a) index.html (b) main.png (c) home.css (d) start.js
  9. 9.🔗 Which address opens when you click this link?
    <a href="https://example.com">Maths fun</a>
    (a) maths.html (b) Maths fun (c) https://example.com (d) art.html
  10. 10.🖌️ Where does the text sit on its line?
    h2 {
      background-color: black;
      text-align: center;
      color: white;
      font-size: 20px;
    }
    (a) on the right (b) on the left (c) in the middle
  11. 11.⚖️ What colour is the text of this element?
    <p class="menu" id="end">Hi</p>
    CSS:
    p { color: blue; }
    p { color: yellow; }
    (a) blue (b) red (c) yellow (d) green
  12. 12.📋 Which list tag shows bullet points? (a) <ul> (b) <ol> (c) <li>
  13. 13.💪 How much empty space (px) is before the first box?
    .row {
      display: flex;
      width: 420px;
      justify-content: center;
    }
    Inside are 4 boxes, each 80px wide (no margins).
  14. 14.⚖️ What colour is the text of this element?
    <p class="menu" id="top">Hi</p>
    CSS:
    .menu { color: black; }
    .menu { color: red; }
    (a) black (b) yellow (c) red (d) blue
  15. 15.🔗 Where does this link open?
    <a href="news.html" target="_blank">Contact us</a>
    (a) in a new tab (b) in the same tab
  16. 16.📝 What does <br> do? (a) makes a list (b) adds a picture (c) makes text bold (d) starts a new line
  17. 17.⚖️ What colour is the text of this element?
    <h2 class="note" id="intro">Hi</h2>
    CSS:
    h2 { color: orange; }
    #intro { color: blue; }
    .note { color: red; }
    (a) red (b) blue (c) black (d) orange
  18. 18.True or false: <main> is the page’s key part. (a) False (b) True
  19. 19.📄 What does the browser tab show for this page?
    <!DOCTYPE html>
    <html>
    <head>
      <title>Cricket Club</title>
    </head>
    <body>
      <h1>Welcome!</h1>
      <p>I like to read.</p>
    </body>
    </html>
    (a) index.html (b) I like to read. (c) Welcome! (d) Cricket Club
  20. 20.🌈 Which hex code is yellow? (a) #ff0000 (b) #ffff00 (c) #0000ff (d) #00ffff
  21. 21.🏷️ Is </h1> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
  22. 22.Which of these is a closing tag? (a) <body> (b) <b> (c) </b> (d) <title>
  23. 23.📛 In <a href="x.html">, what is href? (a) an attribute (b) a closing tag (c) an element name (d) a comment
  24. 24.💪 Which justify-content value equal gaps, none at ends? (a) space-between (b) flex-start (c) center (d) flex-end
  25. 25.🔠 How many <h1> headings should a page usually have? (a) 1 (b) 3 (c) 6 (d) 10
  26. 26.🖼️ Which attribute of <img> tells which image to load? (a) width (b) alt (c) height (d) src
  27. 27.Which of these is an empty tag? (a) <li> (b) <p> (c) <h1> (d) <input>
  28. 28.⚡ Which JavaScript word runs code when true? (a) console.log() (b) let (c) if (d) alert()
  29. 29.📝 Does <b> have a closing tag, or is it an empty tag? (a) an empty tag (b) has a closing tag
  30. 30.💪 How wide (px) is each gap between two boxes?
    .row {
      display: flex;
      width: 200px;
      justify-content: space-between;
    }
    Inside are 2 boxes, each 80px wide (no margins).
  31. 31.🔁 What does i++ do? (a) adds 1 to i (b) takes 1 from i (c) doubles i (d) prints i
  32. 32.True or false: <td> makes one table row. (a) True (b) False
  33. 33.🖼️ Which attribute of <img> shows if the image fails? (a) width (b) alt (c) height (d) src
  34. 34.🖼️ Does <img> need a closing tag? (a) No (b) Yes
  35. 35.🖌️ How big is the text, in px?
    h1 {
      text-align: right;
      font-size: 12px;
      background-color: green;
      color: red;
    }
  36. 36.🖼️ Which picture file does the browser load?
    <img src="tiger.jpg" alt="A tiger asleep" width="300">
    (a) map.png (b) kite.png (c) A tiger asleep (d) tiger.jpg
  37. 37.⚖️ Which selector is the strongest? (a) a class selector (b) an id selector (c) an element selector
  38. 38.💪 How much empty space (px) is left after the last box?
    .row {
      display: flex;
      width: 130px;
      justify-content: flex-start;
    }
    Inside are 2 boxes, each 50px wide (no margins).
  39. 39.🌍 What is the path in this URL?
    https://kids.example.org/about.html
    (a) https (b) /about.html (c) /maths/tables.html (d) kids.example.org
  40. 40.✍️ Which property is set to 20px in this rule?
    .note {
      text-align: center;
      font-size: 20px;
    }
    (a) background-color (b) 20px (c) text-align (d) font-size

Answer key

  1. <h1>
  2. ;
  3. changes the text size
  4. True
  5. /about.html
  6. False
  7. not safe
  8. index.html
  9. https://example.com
  10. in the middle
  11. yellow
  12. <ul>
  13. 50
  14. red
  15. in a new tab
  16. starts a new line
  17. blue
  18. True
  19. Cricket Club
  20. #ffff00
  21. a closing tag
  22. </b>
  23. an attribute
  24. space-between
  25. 1
  26. src
  27. <input>
  28. if
  29. has a closing tag
  30. 40
  31. adds 1 to i
  32. False
  33. alt
  34. No
  35. 12
  36. tiger.jpg
  37. an id selector
  38. 30
  39. /about.html
  40. font-size

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