← Web development final test lesson New set →

Web Development Worksheet: Final Test

HTML and CSS lesson 30: Web development final test · Set 890 · 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.📝 What does a password box show instead of letters? (a) dots (b) capital letters (c) numbers (d) emojis
  2. 2.True or false: HTML adds space around boxes. (a) True (b) False
  3. 3.⚡ What does this code show?
    let name = "Riya";
    alert("Welcome, " + name + "!");
    (a) Riya (b) Welcome, name! (c) Welcome, Riya! (d) name
  4. 4.📊 Which tag holds the whole table? (a) <td> (b) <tr> (c) <caption> (d) <table>
  5. 5.True or false: <input> is an empty tag. (a) False (b) True
  6. 6.🌈 Which colour is #0000ff? (a) cyan (b) white (c) blue (d) bright green
  7. 7.📄 Can HTML on its own keep a high score? (a) Yes (b) No
  8. 8.📊 In a table, which tag is a row? (a) <th> (b) <td> (c) <tb> (d) <tr>
  9. 9.💪 Which justify-content value puts boxes in the middle? (a) flex-start (b) center (c) space-between (d) flex-end
  10. 10.🖼️ Which picture file does the browser load?
    <img src="cake.jpg" alt="Birthday cake" width="400">
    (a) Birthday cake (b) dog.jpg (c) cake.jpg (d) moon.png
  11. 11.📱 The screen is 375px wide. Does the rule inside @media apply?
    p {
      font-size: 24px;
    }
    @media (max-width: 480px) {
      p {
        font-size: 18px;
      }
    }
    (a) No (b) Yes
  12. 12.🔁 What does i++ do? (a) adds 1 to i (b) prints i (c) doubles i (d) takes 1 from i
  13. 13.Which of these is a closing tag? (a) <h1> (b) <body> (c) </h1> (d) <b>
  14. 14.📊 How many cells are in each row?
    <table>
      <tr><th>Name</th><th>Fruit</th><th>Price</th></tr>
      <tr><td>Jamun</td><td>Litchi</td><td>Banana</td></tr>
      <tr><td>Banana</td><td>Orange</td><td>Mango</td></tr>
      <tr><td>Mango</td><td>Banana</td><td>Mango</td></tr>
    </table>
  15. 15.🎨 A CSS file usually ends with which extension? (a) .js (b) .html (c) .png (d) .css
  16. 16.🔢 To build and share your first web page, which comes first: “publish it online” or “plan what to show”? (a) publish it online (b) plan what to show
  17. 17.🎨 Which tag connects an outside CSS file? (a) <css> (b) <a> (c) <img> (d) <link>
  18. 18.True or false: <th> holds the whole table. (a) True (b) False
  19. 19.🌈 Which colour is #00ff00? (a) red (b) bright green (c) magenta (d) cyan
  20. 20.🔒 Is the connection to this address scrambled (encrypted)?
    https://learn.example.com/about.html
    (a) No (b) Yes
  21. 21.True or false: <header> holds the logo and title. (a) True (b) False
  22. 22.True or false: HTTPS scrambles data on its way. (a) False (b) True
  23. 23.🔁 How many numbers does this code print?
    for (let i = 0; i < 20; i = i + 3) {
      console.log(i);
    }
  24. 24.🎨 Which tag holds CSS inside the head? (a) <css> (b) <style> (c) <body> (d) <script>
  25. 25.💬 Does the browser show comments on the page? (a) No (b) Yes
  26. 26.True or false: <caption> gives the table a title. (a) False (b) True
  27. 27.🖌️ Where does the text sit on its line?
    h2 {
      color: red;
      font-size: 24px;
      text-align: right;
      background-color: black;
    }
    (a) on the right (b) in the middle (c) on the left
  28. 28.📝 What does <p> make? (a) a paragraph (b) a table (c) a link (d) a picture
  29. 29.✍️ How many declarations (property: value pairs) are in this rule?
    #top {
      padding: 8px;
      background-color: yellow;
      color: red;
    }
  30. 30.🔁 How many times does this code print “Well done”?
    for (let i = 2; i < 11; i++) {
      console.log("Well done");
    }
  31. 31.⚡ What does this code print? (Look at the quotes!)
    let x = "1";
    let y = 1;
    console.log(x + y);
    (a) 2 (b) Error (c) 11
  32. 32.📱 The screen is 375px wide. Does the rule inside @media apply?
    p {
      font-size: 20px;
    }
    @media (min-width: 480px) {
      p {
        font-size: 26px;
      }
    }
    (a) Yes (b) No
  33. 33.♿ Who uses a screen reader? (a) only robots (b) only teachers (c) only coders (d) people who are blind
  34. 34.🖌️ Which CSS property makes letters bigger? (a) font-family (b) font-size (c) color (d) font-weight
  35. 35.⚡ What does this code show?
    let name = "Meera";
    alert("Well done, " + name + "!");
    (a) Well done, name! (b) Well done, Meera! (c) name (d) Meera
  36. 36.⚖️ What colour is the text of this element?
    <h2 class="big" id="end">Hi</h2>
    CSS:
    #end { color: orange; }
    h2 { color: purple; }
    (a) white (b) black (c) purple (d) orange
  37. 37.True or false: <ul> is an empty tag. (a) False (b) True
  38. 38.📝 Does <title> have a closing tag, or is it an empty tag? (a) an empty tag (b) has a closing tag
  39. 39.True or false: a code editor answers page requests. (a) True (b) False
  40. 40.📄 Can HTML on its own make tables? (a) No (b) Yes

Answer key

  1. dots
  2. False
  3. Welcome, Riya!
  4. <table>
  5. True
  6. blue
  7. No
  8. <tr>
  9. center
  10. cake.jpg
  11. Yes
  12. adds 1 to i
  13. </h1>
  14. 3
  15. .css
  16. plan what to show
  17. <link>
  18. False
  19. bright green
  20. Yes
  21. True
  22. True
  23. 7
  24. <style>
  25. No
  26. True
  27. on the right
  28. a paragraph
  29. 3
  30. 9
  31. 11
  32. No
  33. people who are blind
  34. font-size
  35. Well done, Meera!
  36. orange
  37. False
  38. has a closing tag
  39. False
  40. Yes

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