← Web development final test lesson New set →

Web Development Worksheet: Final Test

HTML and CSS lesson 30: Web development final test · Set 611 · 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.📦 In the box model, which part is the line round the box? (a) margin (b) border (c) padding (d) content
  2. 2.📝 On how many lines does the browser show this paragraph?
    <p>Birds sing<br>Stars shine<br>Kites fly high</p>
  3. 3.⚖️ Which selector is the weakest? (a) a class selector (b) an id selector (c) an element selector
  4. 4.What does text-align do? (a) colours behind the text (b) makes letters bigger (c) centres a heading (d) makes the text bold
  5. 5.💬 Which text will NOT show on the page?
    <p>My pets</p>
    <p>Rain today</p>
    <!-- <p>The red kite</p> -->
    (a) The red kite (b) My pets (c) Rain today
  6. 6.📝 How many paragraphs does this code make?
    <p>Our school trip</p>
    <p>Our school trip</p>
    <h2>Fun facts</h2>
    <p>I love mangoes.</p>
    <h2>My best friend</h2>
    <p>My best friend</p>
  7. 7.📱 The screen is 1366px wide. What font-size (px) does the paragraph get?
    p {
      font-size: 16px;
    }
    @media (max-width: 600px) {
      p {
        font-size: 14px;
      }
    }
  8. 8.🚀 Which file should this code go in: body { margin: 0; } (a) index.html (b) style.css (c) script.js
  9. 9.🔗 Which address opens when you click this link?
    <a href="games.html">Visit the site</a>
    (a) games.html (b) Visit the site (c) contact.html (d) about.html
  10. 10.✍️ In color: blue; which part is the property? (a) color (b) ; (c) blue (d) :
  11. 11.🎯 How many elements on a page should have the same id? (a) 1 (b) 5 (c) 2 (d) any number
  12. 12.📝 How many paragraphs does this code make?
    <p>The red kite</p>
    <h2>My best friend</h2>
    <p>Fun facts</p>
  13. 13.True or false: <article> holds a news story. (a) True (b) False
  14. 14.🔐 Is abcd1234 a strong or a weak password? (a) strong (b) weak
  15. 15.What does justify-content: center do? (a) puts boxes in the middle (b) packs boxes at the start (c) equal gaps, none at ends (d) packs boxes at the end
  16. 16.🔢 To build and share your first web page, which comes first: “test in a browser” or “plan what to show”? (a) test in a browser (b) plan what to show
  17. 17.💪 How much empty space (px) is before the first box?
    .row {
      display: flex;
      width: 220px;
      justify-content: center;
    }
    Inside are 2 boxes, each 50px wide (no margins).
  18. 18.🖼️ Which attribute of <img> sets how wide it is? (a) alt (b) src (c) width (d) height
  19. 19.📄 What is the big heading shown on this page?
    <!DOCTYPE html>
    <html>
    <head>
      <title>Space Facts</title>
    </head>
    <body>
      <h1>My drawings</h1>
      <p>Here is my best one.</p>
    </body>
    </html>
    (a) body (b) Here is my best one. (c) My drawings (d) Space Facts
  20. 20.🚀 Which file should this code go in: p { color: red; } (a) index.html (b) style.css (c) script.js
  21. 21.✍️ What value is given to padding in this rule?
    .box {
      border: 2px solid;
      padding: 8px;
    }
    (a) bold (b) padding (c) 2px solid (d) 8px
  22. 22.📄 What does the browser tab show for this page?
    <!DOCTYPE html>
    <html>
    <head>
      <title>Art Gallery</title>
    </head>
    <body>
      <h1>Welcome!</h1>
      <p>I like to read.</p>
    </body>
    </html>
    (a) Art Gallery (b) I like to read. (c) index.html (d) Welcome!
  23. 23.Which of these is a weak password? (a) Blue@Tiger_74 (b) Kite_Fl1es@Dawn (c) 123456 (d) Rain#Drop_42!
  24. 24.🌍 What is the protocol in this URL?
    https://learn.example.com/about.html
    (a) http (b) https (c) /about.html (d) learn.example.com
  25. 25.What is <input type="submit"> for? (a) is for one line of words (b) sends the form (c) lets you tick many (d) takes only numbers
  26. 26.🖌️ Which CSS property makes letters bigger? (a) font-weight (b) background-color (c) font-size (d) font-family
  27. 27.🌈 In #rrggbb, which colour do the last two digits give? (a) green (b) red (c) white (d) blue
  28. 28.💬 How many paragraphs show on the page?
    <p>Hello, world!</p>
    <!-- <p>Fun facts</p> -->
    <!-- <p>My best friend</p> -->
  29. 29.🔢 When you open a web page, what comes right after “you type the URL”? (a) the server sends files (b) DNS finds the server (c) the browser shows it (d) the browser asks it
  30. 30.⚡ What does JavaScript add to a web page? (a) actions and changes (b) the page title (c) only colours (d) the domain name
  31. 31.True or false: margin is the gap to other boxes. (a) False (b) True
  32. 32.Which of these is an empty tag? (a) <p> (b) <input> (c) <li> (d) <h1>
  33. 33.🔢 In a basic web page file, which comes LAST? (a) <html> (b) </html> (c) </body> (d) </head>
  34. 34.📝 Which input type sends the form? (a) date (b) submit (c) text (d) email
  35. 35.📋 Which list shows the steps of a recipe best? (a) <br> (b) <ul> (c) <ol> (d) <hr>
  36. 36.True or false: <h1> is an empty tag. (a) False (b) True
  37. 37.True or false: in <img>, height shows if the image fails. (a) True (b) False
  38. 38.📝 Which tag makes a drop-down list? (a) <select> (b) <li> (c) <ol> (d) <ul>
  39. 39.Which of these is an opening tag? (a) </title> (b) <p> (c) </b> (d) </p>
  40. 40.🧭 Is <header> semantic or not semantic? (a) not semantic (b) semantic

Answer key

  1. border
  2. 3
  3. an element selector
  4. centres a heading
  5. The red kite
  6. 4
  7. 16
  8. style.css
  9. games.html
  10. color
  11. 1
  12. 2
  13. True
  14. weak
  15. puts boxes in the middle
  16. plan what to show
  17. 60
  18. width
  19. My drawings
  20. style.css
  21. 8px
  22. Art Gallery
  23. 123456
  24. https
  25. sends the form
  26. font-size
  27. blue
  28. 1
  29. DNS finds the server
  30. actions and changes
  31. True
  32. <input>
  33. </html>
  34. submit
  35. <ol>
  36. False
  37. False
  38. <select>
  39. <p>
  40. semantic

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