← Web development final test lesson New set →

Web Development Worksheet: Final Test

HTML and CSS lesson 30: Web development final test · Set 654 · 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.🧭 Who is helped most by semantic tags? (a) screen-reader users (b) nobody (c) only the printer (d) only the server
  2. 2.🧩 Which language checks a quiz answer? (a) HTML (b) JavaScript (c) CSS
  3. 3.True or false: <b> has a closing tag. (a) True (b) False
  4. 4.📝 How many paragraphs does this code make?
    <p>Cricket is fun.</p>
    <p>My pets</p>
    <p>Hello, world!</p>
    <p>Rain today</p>
    <h2>I love mangoes.</h2>
    <p>Good morning!</p>
  5. 5.📋 Which list suits a shopping list in any order? (a) <hr> (b) <ul> (c) <ol> (d) <br>
  6. 6.🔗 Which address opens when you click this link?
    <a href="games.html">School news</a>
    (a) contact.html (b) games.html (c) about.html (d) School news
  7. 7.Which of these is true of <header>? (a) sits at the very top (b) holds extra side notes (c) holds the menu of links (d) holds copyright notes
  8. 8.🔠 Which heading shows the BIGGEST text: <h1>, <h5>, <h4> or <h6>? (a) <h4> (b) <h1> (c) <h5> (d) <h6>
  9. 9.🔗 Which address opens when you click this link?
    <a href="news.html">School news</a>
    (a) news.html (b) quiz.html (c) School news (d) games.html
  10. 10.True or false: to share your OTP is safe. (a) False (b) True
  11. 11.True or false: <title> is an empty tag. (a) True (b) False
  12. 12.Which colour pair is hard to read? (a) red on green (b) black on white (c) white on dark blue (d) white on black
  13. 13.✍️ How many declarations (property: value pairs) are in this rule?
    .box {
      color: red;
    }
  14. 14.True or false: a web server hosts websites online. (a) True (b) False
  15. 15.⚡ What number does this code print?
    let a = 42;
    let b = 8;
    console.log(a - b);
  16. 16.📦 How much space across (px) does this box take in all, margin included?
    .box {
      width: 300px;
      padding: 10px;
      border: 1px solid black;
      margin: 0px;
    }
  17. 17.📱 The screen is 540px wide. Does the rule inside @media apply?
    p {
      font-size: 20px;
    }
    @media (min-width: 1024px) {
      p {
        font-size: 22px;
      }
    }
    (a) Yes (b) No
  18. 18.🎨 Which tag connects an outside CSS file? (a) <css> (b) <a> (c) <link> (d) <img>
  19. 19.What does justify-content: flex-end do? (a) puts boxes in the middle (b) equal gaps, none at ends (c) packs boxes at the end (d) packs boxes at the start
  20. 20.🔗 Which address opens when you click this link?
    <a href="https://example.com">Maths fun</a>
    (a) art.html (b) https://example.com (c) maths.html (d) Maths fun
  21. 21.📝 On how many lines does the browser show this paragraph?
    <p>Rivers flow<br>Stars shine<br>Roses are red<br>Birds sing<br>Kites fly high</p>
  22. 22.🔗 Which attribute holds the address of a link? (a) id (b) src (c) href (d) alt
  23. 23.⚖️ What colour is the text of this element?
    <p class="box" id="main">Hi</p>
    CSS:
    #main { color: orange; }
    .box { color: white; }
    p { color: red; }
    (a) red (b) purple (c) orange (d) white
  24. 24.True or false: in <img>, width names the picture file. (a) True (b) False
  25. 25.True or false: <ul> lists things in any order. (a) False (b) True
  26. 26.True or false: <ol> is an ordered list. (a) False (b) True
  27. 27.True or false: in <img>, src sets how wide it is. (a) True (b) False
  28. 28.💬 How does an HTML comment start? (a) # (b) <!-- (c) // (d) /*
  29. 29.🌈 Which colour is rgb(0, 255, 0)? (a) yellow (b) magenta (c) bright green (d) cyan
  30. 30.♿ Does this help everyone, or make the page harder to use: use headings in order? (a) helps everyone (b) makes it harder
  31. 31.🧭 Is <section> semantic or not semantic? (a) not semantic (b) semantic
  32. 32.Which of these is an opening tag? (a) <title> (b) </li> (c) </title> (d) </p>
  33. 33.🌍 What is the protocol in this URL?
    https://www.example.com/maths/tables.html
    (a) /maths/tables.html (b) http (c) https (d) www.example.com
  34. 34.🧩 Which language changes the text size? (a) CSS (b) HTML (c) JavaScript
  35. 35.💬 Why do coders write comments? (a) to add colour (b) to leave notes (c) to make links (d) to show pictures
  36. 36.Which of these is true of <aside>? (a) holds extra side notes (b) holds the menu of links (c) holds the main content (d) holds the logo and title
  37. 37.🔁 What number does this code print?
    let total = 0;
    for (let i = 1; i <= 10; i++) {
      total = total + 5;
    }
    console.log(total);
  38. 38.True or false: body is an id selector. (a) False (b) True
  39. 39.🖼️ Which attribute of <img> tells which image to load? (a) height (b) width (c) src (d) alt
  40. 40.🎯 What kind of selector is #end? (a) a class selector (b) an id selector (c) an element selector

Answer key

  1. screen-reader users
  2. JavaScript
  3. True
  4. 5
  5. <ul>
  6. games.html
  7. sits at the very top
  8. <h1>
  9. news.html
  10. False
  11. False
  12. red on green
  13. 1
  14. True
  15. 34
  16. 322
  17. No
  18. <link>
  19. packs boxes at the end
  20. https://example.com
  21. 5
  22. href
  23. orange
  24. False
  25. True
  26. True
  27. False
  28. <!--
  29. bright green
  30. helps everyone
  31. semantic
  32. <title>
  33. https
  34. CSS
  35. to leave notes
  36. holds extra side notes
  37. 50
  38. False
  39. src
  40. an id selector

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