← Web development final test lesson New set →

Web Development Worksheet: Final Test

HTML and CSS lesson 30: Web development final test · Set 725 · 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.🔐 Is riya2014 a strong or a weak password? (a) strong (b) weak
  2. 2.True or false: <footer> holds a side box of tips. (a) True (b) False
  3. 3.Which of these is not safe to do online? (a) think before you post (b) tell a trusted adult (c) type a password on http (d) check for https first
  4. 4.🛡️ Is it safe to use the same password on every site? (a) No (b) Yes
  5. 5.What does justify-content: space-between do? (a) packs boxes at the start (b) puts boxes in the middle (c) equal gaps, none at ends (d) packs boxes at the end
  6. 6.Which of these is true of a web browser? (a) sends pages over the net (b) stores a website’s files (c) has an address bar (d) is where we type code
  7. 7.📱 The screen is 375px wide. Does the rule inside @media apply?
    p {
      font-size: 16px;
    }
    @media (max-width: 480px) {
      p {
        font-size: 10px;
      }
    }
    (a) No (b) Yes
  8. 8.📱 The screen is 700px wide. Does the rule inside @media apply?
    p {
      font-size: 20px;
    }
    @media (min-width: 768px) {
      p {
        font-size: 24px;
      }
    }
    (a) No (b) Yes
  9. 9.True or false: a code editor stores a website’s files. (a) True (b) False
  10. 10.🌍 Which one asks for a web page? (a) the server (b) the browser (c) the URL (d) HTTPS
  11. 11.Which of these goes in the body? (a) <link rel="stylesheet"> (b) <ul> (c) <title> (d) <style>
  12. 12.🔠 How many headings are in this code?
    <h1>I love mangoes.</h1>
    <h4>Hello, world!</h4>
    <p>I love mangoes.</p>
  13. 13.True or false: <article> holds one blog post. (a) True (b) False
  14. 14.🎯 What kind of selector is .menu? (a) a class selector (b) an element selector (c) an id selector
  15. 15.🔁 What does this code print?
    let age = 41;
    if (age < 16) {
      console.log("teen");
    } else {
      console.log("child");
    }
    (a) teen (b) child
  16. 16.🎯 What kind of selector is .big? (a) an element selector (b) a class selector (c) an id selector
  17. 17.📊 Are <th> cells shown bold and centred by default? (a) Yes (b) No
  18. 18.📱 The screen is 320px wide. Does the rule inside @media apply?
    p {
      font-size: 12px;
    }
    @media (min-width: 1024px) {
      p {
        font-size: 14px;
      }
    }
    (a) Yes (b) No
  19. 19.🖼️ How many pixels wide is the picture drawn?
    <img src="bus.jpg" alt="Our school bus" width="150">
  20. 20.⚡ Which word makes a new variable? (a) let (b) make (c) put (d) give
  21. 21.🌈 Which colour is rgb(0, 0, 255)? (a) bright green (b) blue (c) magenta (d) white
  22. 22.🔁 What does this code print?
    let temp = 18;
    if (temp >= 36) {
      console.log("Hot");
    } else {
      console.log("Cool");
    }
    (a) Cool (b) Hot
  23. 23.🌗 Is white on black easy or hard to read? (a) hard to read (b) easy to read
  24. 24.🔁 What number does this code print?
    let total = 0;
    for (let i = 1; i <= 9; i++) {
      total = total + 4;
    }
    console.log(total);
  25. 25.🖌️ What colour is behind the letters?
    li {
      text-align: left;
      color: white;
      font-size: 12px;
      background-color: blue;
    }
    (a) red (b) blue (c) white
  26. 26.True or false: margin is space inside the border. (a) True (b) False
  27. 27.🎯 Which CSS selector matches this element?
    <p class="note" id="main">Hello</p>
    (a) #note (b) h1 (c) p (d) .big
  28. 28.📦 How wide (px) is this box from the outer edge of its left border to the outer edge of its right border?
    .box {
      width: 50px;
      padding: 25px;
      border: 5px solid black;
      margin: 10px;
    }
  29. 29.🖌️ What colour are the letters?
    li {
      background-color: purple;
      color: blue;
      font-size: 28px;
      text-align: left;
    }
    (a) purple (b) green (c) blue
  30. 30.📦 How much space across (px) does this box take in all, margin included?
    .box {
      width: 280px;
      padding: 30px;
      border: 2px solid black;
      margin: 0px;
    }
  31. 31.📋 What number does the browser show next to “Papaya”?
    <ol start="4">
      <li>Jamun</li>
      <li>Banana</li>
      <li>Papaya</li>
      <li>Mango</li>
    </ol>
  32. 32.🎯 Which CSS selector matches this element?
    <li class="menu" id="intro">Hello</li>
    (a) #menu (b) .intro (c) .note (d) #intro
  33. 33.True or false: .note is an element selector. (a) False (b) True
  34. 34.True or false: <p> goes in the body. (a) True (b) False
  35. 35.📱 What does a media query check? (a) the screen width (b) the time of day (c) the battery level (d) the page title
  36. 36.Which of these does CSS do? (a) checks a quiz answer (b) changes the text size (c) reacts to a button click (d) changes the page live
  37. 37.🖼️ Which attribute of <img> sets how tall it is? (a) width (b) src (c) alt (d) height
  38. 38.📋 Does this list show bullets or numbers?
    <ul>
      <li>Banana</li>
      <li>Mango</li>
    </ul>
    (a) bullets (b) numbers
  39. 39.📋 What number does the browser show next to “Guava”?
    <ol>
      <li>Banana</li>
      <li>Guava</li>
      <li>Papaya</li>
    </ol>
  40. 40.🏷️ Is </p> an opening tag or a closing tag? (a) an opening tag (b) a closing tag

Answer key

  1. weak
  2. False
  3. type a password on http
  4. No
  5. equal gaps, none at ends
  6. has an address bar
  7. Yes
  8. No
  9. False
  10. the browser
  11. <ul>
  12. 2
  13. True
  14. a class selector
  15. child
  16. a class selector
  17. Yes
  18. No
  19. 150
  20. let
  21. blue
  22. Cool
  23. easy to read
  24. 36
  25. blue
  26. False
  27. p
  28. 110
  29. blue
  30. 344
  31. 6
  32. #intro
  33. False
  34. True
  35. the screen width
  36. changes the text size
  37. height
  38. bullets
  39. 2
  40. a closing tag

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