← Web development final test lesson New set →

Web Development Worksheet: Final Test

HTML and CSS lesson 30: Web development final test · Set 222 · 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.True or false: HTML on its own cannot make tables. (a) False (b) True
  2. 2.🚀 Which file should this code go in: <a href="a.html">Go</a> (a) index.html (b) script.js (c) style.css
  3. 3.True or false: <nav> holds the menu of links. (a) True (b) False
  4. 4.🧭 Which semantic tag holds the menu of links? (a) <aside> (b) <nav> (c) <header> (d) <main>
  5. 5.💬 Which text will NOT show on the page?
    <p>Fun facts</p>
    <!-- <p>I love mangoes.</p> -->
    <p>My pets</p>
    <p>Rain today</p>
    (a) I love mangoes. (b) Fun facts (c) Rain today (d) My pets
  6. 6.✍️ What is the selector in this CSS rule?
    li {
      font-weight: bold;
      color: red;
      border: 2px solid;
    }
    (a) red (b) font-weight (c) body (d) li
  7. 7.💪 Which justify-content value equal gaps, none at ends? (a) space-between (b) flex-end (c) center (d) flex-start
  8. 8.🔠 Which heading shows the BIGGEST text: <h4>, <h2>, <h6> or <h5>? (a) <h4> (b) <h5> (c) <h6> (d) <h2>
  9. 9.True or false: let score = 0; goes in style.css. (a) True (b) False
  10. 10.🏷️ Is <li> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
  11. 11.🔍 Which is the odd one out? (a) saves our .html files (b) opens web pages for us (c) colours code to help us (d) is where we type code
  12. 12.💪 How much empty space (px) is before the first box?
    .row {
      display: flex;
      width: 240px;
      justify-content: flex-end;
    }
    Inside are 3 boxes, each 60px wide (no margins).
  13. 13.🏷️ What does a closing tag have that an opening tag does not? (a) a hash # (b) a dot . (c) a dollar $ (d) a slash /
  14. 14.🔁 What does this code print?
    let score = 37;
    if (score > 10) {
      console.log("You win");
    } else {
      console.log("Play again");
    }
    (a) You win (b) Play again
  15. 15.📦 How much space top to bottom (px) does this box take in all, margin included?
    .box {
      height: 110px;
      padding: 10px;
      border: 2px solid black;
      margin: 0px;
    }
  16. 16.What does color do? (a) centres a heading (b) colours behind the text (c) sets the letter colour (d) makes letters bigger
  17. 17.✍️ How many declarations (property: value pairs) are in this rule?
    p {
      border: 2px solid;
      font-size: 20px;
    }
  18. 18.🔗 Which address opens when you click this link?
    <a href="about.html">Contact us</a>
    (a) https://example.com (b) contact.html (c) about.html (d) Contact us
  19. 19.⚡ Which JavaScript word repeats code? (a) for (b) console.log() (c) let (d) alert()
  20. 20.⚡ What number does this code print?
    let marks = 5;
    marks = marks + 2;
    marks = marks - 7;
    console.log(marks);
  21. 21.Which of these is true of a web server? (a) colours code to help us (b) sends pages over the net (c) is where we type code (d) shows pages from the web
  22. 22.⚖️ Two rules with the same selector set a colour. Which one wins? (a) the shorter one (b) the later one (c) the first one (d) neither
  23. 23.📦 How wide (px) is this box from the outer edge of its left border to the outer edge of its right border?
    .box {
      width: 110px;
      padding: 15px;
      border: 4px solid black;
      margin: 0px;
    }
  24. 24.💬 Can anyone read your comments by viewing the page source? (a) No (b) Yes
  25. 25.🌗 Is dark grey on white easy or hard to read? (a) hard to read (b) easy to read
  26. 26.🛡️ Online: is it safe to use a strong password? (a) not safe (b) safe
  27. 27.🔐 Is Mango#Kite29! a strong or a weak password? (a) strong (b) weak
  28. 28.💬 How many paragraphs show on the page?
    <!-- <p>Our school trip</p> -->
    <p>I love mangoes.</p>
    <p>The red kite</p>
    <p>Rain today</p>
  29. 29.📝 At most, how many of these can be chosen at the same time?
    <form>
      <input type="checkbox" name="sport"> Cricket
      <input type="checkbox" name="sport"> Kabaddi
      <input type="checkbox" name="sport"> Chess
      <input type="checkbox" name="sport"> Hockey
      <input type="checkbox" name="sport"> Football
    </form>
  30. 30.True or false: in <img>, alt is read by screen readers. (a) True (b) False
  31. 31.🧭 Why use <nav> instead of <div> for a menu? (a) it makes text red (b) it tells its meaning (c) it adds pictures (d) it loads faster
  32. 32.📋 What number does the browser show next to “Grapes”?
    <ol start="4">
      <li>Orange</li>
      <li>Grapes</li>
      <li>Banana</li>
    </ol>
  33. 33.🎯 Which CSS selector matches this element?
    <h1 class="big" id="logo">Hello</h1>
    (a) .big (b) #end (c) #big (d) .logo
  34. 34.🔠 Which heading shows the SMALLEST text: <h3>, <h5>, <h1> or <h4>? (a) <h5> (b) <h4> (c) <h3> (d) <h1>
  35. 35.True or false: “label every form box” helps everyone use the page. (a) False (b) True
  36. 36.🛡️ Is it safe to use the same password on every site? (a) Yes (b) No
  37. 37.📝 Does <h1> have a closing tag, or is it an empty tag? (a) an empty tag (b) has a closing tag
  38. 38.🏷️ HTML marks up text using ___. (a) pixels (b) wires (c) keys (d) tags
  39. 39.🖼️ Which attribute of <img> sets how tall it is? (a) width (b) height (c) alt (d) src
  40. 40.Which of these is true of a web server? (a) saves our .html files (b) shows pages from the web (c) has an address bar (d) hosts websites online

Answer key

  1. False
  2. index.html
  3. True
  4. <nav>
  5. I love mangoes.
  6. li
  7. space-between
  8. <h2>
  9. False
  10. an opening tag
  11. opens web pages for us
  12. 60
  13. a slash /
  14. You win
  15. 134
  16. sets the letter colour
  17. 2
  18. about.html
  19. for
  20. 0
  21. sends pages over the net
  22. the later one
  23. 148
  24. Yes
  25. easy to read
  26. safe
  27. strong
  28. 3
  29. 5
  30. True
  31. it tells its meaning
  32. 5
  33. .big
  34. <h5>
  35. True
  36. No
  37. has a closing tag
  38. tags
  39. height
  40. hosts websites online

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