← Web development final test lesson New set →

Web Development Worksheet: Final Test

HTML and CSS lesson 30: Web development final test · Set 342 · 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 property is set to red in this rule?
    .note {
      font-style: italic;
      border: 2px solid;
      color: red;
    }
    (a) font-size (b) color (c) red (d) text-align
  2. 2.🔍 Which line is missing its closing tag?
    line 1: <em>Fun facts</em>
    line 2: <small>My pets
    line 3: <strong>Hello, world!</strong>
    (a) line 3 (b) line 2 (c) line 1
  3. 3.Which of these is true of <nav>? (a) is the page’s key part (b) holds the main content (c) helps you move around (d) holds one blog post
  4. 4.📛 In <a href="x.html">, what is href? (a) a comment (b) a closing tag (c) an element name (d) an attribute
  5. 5.🖌️ Where does the text sit on its line?
    h1 {
      background-color: blue;
      font-size: 20px;
      color: green;
      text-align: left;
    }
    (a) in the middle (b) on the right (c) on the left
  6. 6.🧩 Which language shows a pop-up message? (a) JavaScript (b) CSS (c) HTML
  7. 7.🚀 What is the home page file of a website usually called? (a) home.css (b) start.js (c) index.html (d) main.png
  8. 8.🔐 Is 123456 a strong or a weak password? (a) weak (b) strong
  9. 9.🔗 Where does this link open?
    <a href="games.html">Maths fun</a>
    (a) in a new tab (b) in the same tab
  10. 10.🧭 Is <span> semantic or not semantic? (a) not semantic (b) semantic
  11. 11.🏷️ Is <li> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
  12. 12.📦 In the box model, which part is the line round the box? (a) margin (b) padding (c) border (d) content
  13. 13.📱 The screen is 320px wide. What font-size (px) does the paragraph get?
    p {
      font-size: 24px;
    }
    @media (max-width: 768px) {
      p {
        font-size: 20px;
      }
    }
  14. 14.📋 What number does the browser show next to “Orange”?
    <ol>
      <li>Papaya</li>
      <li>Grapes</li>
      <li>Orange</li>
    </ol>
  15. 15.📝 Which input type sends the form? (a) number (b) checkbox (c) submit (d) date
  16. 16.🏷️ Is <p> an opening tag or a closing tag? (a) a closing tag (b) an opening tag
  17. 17.📄 What does the browser tab show for this page?
    <!DOCTYPE html>
    <html>
    <head>
      <title>Cricket Club</title>
    </head>
    <body>
      <h1>Planets</h1>
      <p>Mars is red.</p>
    </body>
    </html>
    (a) Mars is red. (b) Cricket Club (c) index.html (d) Planets
  18. 18.🔍 One closing tag is missing. Which one?
    <h3>Fun facts</h3>
    <i>Cricket is fun.</i>
    <h2>My best friend
    (a) </small> (b) </i> (c) </h2> (d) </h3>
  19. 19.Which of these is not safe to do online? (a) log out on shared PCs (b) tell a trusted adult (c) use a strong password (d) meet an online stranger
  20. 20.Which of these is a strong password? (a) 111111 (b) iloveyou (c) Blue@Tiger_74 (d) qwerty
  21. 21.🔁 How many numbers does this code print?
    for (let i = 0; i < 5; i = i + 4) {
      console.log(i);
    }
  22. 22.True or false: HTML on its own can run a game loop. (a) True (b) False
  23. 23.💬 How many paragraphs show on the page?
    <p>My pets</p>
    <!-- <p>Rain today</p> -->
    <!-- <p>Hello, world!</p> -->
    <!-- <p>Fun facts</p> -->
  24. 24.🌈 How many pairs of hex digits are in a colour like #ff8800? (a) 2 (b) 3 (c) 6 (d) 4
  25. 25.True or false: <caption> holds the whole table. (a) False (b) True
  26. 26.♿ Does this help everyone, or make the page harder to use: use headings in order? (a) makes it harder (b) helps everyone
  27. 27.Which colour pair is hard to read? (a) blue on purple (b) black on white (c) white on black (d) white on dark blue
  28. 28.♿ Is this heading order correct (no level skipped)?
    <h1> → <h1> → <h2> → <h3>
    (a) No (b) Yes
  29. 29.Which of these is true of a code editor? (a) is where we type code (b) shows pages from the web (c) stores a website’s files (d) turns HTML into a page
  30. 30.🖌️ Which CSS property picks the font style? (a) font-weight (b) font-family (c) text-align (d) font-size
  31. 31.✍️ Which property is set to 8px in this rule?
    li {
      width: 300px;
      font-style: italic;
      padding: 8px;
      background-color: yellow;
    }
    (a) 8px (b) font-weight (c) border (d) padding
  32. 32.🏷️ What does a closing tag have that an opening tag does not? (a) a hash # (b) a dollar $ (c) a dot . (d) a slash /
  33. 33.♿ A part of the page is under a <h4> heading. Which tag should its sub-heading use? (a) <h5> (b) <h1> (c) <h2> (d) <h3>
  34. 34.🏷️ Which is the closing tag for <h2>? (a) </h2> (b) <h2> (c) <\h2> (d) <h2/>
  35. 35.🔍 One closing tag is missing. Which one?
    <em>Hello, world!
    <h2>The red kite</h2>
    <h3>My best friend</h3>
    (a) </h2> (b) </h3> (c) </em> (d) </i>
  36. 36.🔍 Which is the odd one out? (a) colours code to help us (b) sends pages over the net (c) saves our .html files (d) is where we type code
  37. 37.True or false: HTTPS asks for a web page. (a) False (b) True
  38. 38.True or false: <ul> is an unordered list. (a) True (b) False
  39. 39.True or false: CSS rounds box corners. (a) False (b) True
  40. 40.True or false: <p> is an empty tag. (a) True (b) False

Answer key

  1. color
  2. line 2
  3. helps you move around
  4. an attribute
  5. on the left
  6. JavaScript
  7. index.html
  8. weak
  9. in the same tab
  10. not semantic
  11. an opening tag
  12. border
  13. 20
  14. 3
  15. submit
  16. an opening tag
  17. Cricket Club
  18. </h2>
  19. meet an online stranger
  20. Blue@Tiger_74
  21. 2
  22. False
  23. 1
  24. 3
  25. False
  26. helps everyone
  27. blue on purple
  28. Yes
  29. is where we type code
  30. font-family
  31. padding
  32. a slash /
  33. <h5>
  34. </h2>
  35. </em>
  36. sends pages over the net
  37. False
  38. True
  39. True
  40. False

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