← Web development final test lesson New set →

Web Development Worksheet: Final Test

HTML and CSS lesson 30: Web development final test · Set 838 · 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 a basic web page file, which comes LAST? (a) </head> (b) </body> (c) <html> (d) </html>
  2. 2.True or false: the content is the gap round content. (a) False (b) True
  3. 3.⚡ Where does console.log() show its output? (a) on the printer (b) on the title bar (c) in the console (d) in the address bar
  4. 4.🌈 Which colour is #00ff00? (a) bright green (b) magenta (c) cyan (d) blue
  5. 5.⚖️ Which selector is the weakest? (a) a class selector (b) an element selector (c) an id selector
  6. 6.True or false: <header> holds the logo and title. (a) False (b) True
  7. 7.♿ Does this help everyone, or make the page harder to use: skipping heading levels? (a) helps everyone (b) makes it harder
  8. 8.🛡️ A pop-up says you won a prize and asks for your password. What do you do? (a) share it with friends (b) click it twice (c) type the password (d) close it, tell an adult
  9. 9.🔢 When you open a web page, what comes right after “the browser asks it”? (a) DNS finds the server (b) the server sends files (c) the browser shows it (d) you type the URL
  10. 10.🌐 Which one answers page requests? (a) a web browser (b) a code editor (c) a web server
  11. 11.📱 The screen is 320px wide. Does the rule inside @media apply?
    p {
      font-size: 24px;
    }
    @media (max-width: 1024px) {
      p {
        font-size: 18px;
      }
    }
    (a) Yes (b) No
  12. 12.💪 How much empty space (px) is left after the last box?
    .row {
      display: flex;
      width: 130px;
      justify-content: flex-start;
    }
    Inside are 3 boxes, each 40px wide (no margins).
  13. 13.🎯 Which sign starts an id selector? (a) # (b) @ (c) & (d) .
  14. 14.What is <input type="text"> for? (a) is for an email address (b) hides what you type (c) is for one line of words (d) lets you pick only one
  15. 15.🔁 What number does this code print?
    let total = 0;
    for (let i = 1; i <= 10; i++) {
      total = total + i;
    }
    console.log(total);
  16. 16.🧭 Who is helped most by semantic tags? (a) nobody (b) only the server (c) screen-reader users (d) only the printer
  17. 17.💬 Which text will NOT show on the page?
    <p>Fun facts</p>
    <!-- <p>The red kite</p> -->
    <p>Good morning!</p>
    <p>Our school trip</p>
    (a) Fun facts (b) Good morning! (c) Our school trip (d) The red kite
  18. 18.✍️ What value is given to background-color in this rule?
    p {
      font-size: 20px;
      background-color: yellow;
    }
    (a) 8px (b) yellow (c) background-color (d) 10px
  19. 19.🌍 Which one is the page’s address? (a) the browser (b) HTTPS (c) the server (d) the URL
  20. 20.True or false: <table> goes in the head. (a) True (b) False
  21. 21.📱 What does a media query check? (a) the page title (b) the battery level (c) the time of day (d) the screen width
  22. 22.🔠 Which heading shows the SMALLEST text: <h5>, <h2>, <h1> or <h3>? (a) <h2> (b) <h3> (c) <h5> (d) <h1>
  23. 23.🔁 How many times does this code print “Hello”?
    for (let i = 0; i <= 2; i++) {
      console.log("Hello");
    }
  24. 24.🖼️ Which attribute of <img> shows if the image fails? (a) width (b) src (c) alt (d) height
  25. 25.💬 How many paragraphs show on the page?
    <!-- <p>The red kite</p> -->
    <p>Good morning!</p>
    <!-- <p>Rain today</p> -->
    <!-- <p>I love mangoes.</p> -->
    <p>Cricket is fun.</p>
  26. 26.🔠 How many headings are in this code?
    <h1>My best friend</h1>
    <h3>The red kite</h3>
    <h3>Hello, world!</h3>
    <h4>Our school trip</h4>
  27. 27.🔠 Which heading shows the SMALLEST text: <h2>, <h3>, <h6> or <h1>? (a) <h3> (b) <h6> (c) <h1> (d) <h2>
  28. 28.Which of these does CSS do? (a) gives the page structure (b) puts a picture on a page (c) rounds box corners (d) changes the page live
  29. 29.Which colour pair is hard to read? (a) yellow on black (b) pink on red (c) dark grey on white (d) white on black
  30. 30.🌈 Which colour is #ff0000? (a) bright green (b) magenta (c) red (d) blue
  31. 31.🎨 Which tag connects an outside CSS file? (a) <css> (b) <img> (c) <a> (d) <link>
  32. 32.💾 A web page file usually ends with which extension? (a) .txt (b) .mp3 (c) .html (d) .png
  33. 33.🔍 Which is the odd one out? (a) has an address bar (b) stores a website’s files (c) shows pages from the web (d) opens web pages for us
  34. 34.🚀 Should file names have spaces, like my page.html? (a) No (b) Yes
  35. 35.🌍 What is the domain name in this URL?
    http://school.example.in/games/chess.html
    (a) /games/chess.html (b) http (c) school.example.in (d) www.example.net
  36. 36.True or false: <input type="radio"> takes only numbers. (a) False (b) True
  37. 37.True or false: console.log(5 + 2); goes in index.html. (a) False (b) True
  38. 38.📋 Does this list show bullets or numbers?
    <ul>
      <li>Mango</li>
      <li>Litchi</li>
      <li>Banana</li>
    </ul>
    (a) numbers (b) bullets
  39. 39.True or false: #top is a class selector. (a) True (b) False
  40. 40.🖌️ Where does the text sit on its line?
    h2 {
      text-align: right;
      background-color: orange;
      color: purple;
      font-size: 12px;
    }
    (a) on the right (b) in the middle (c) on the left

Answer key

  1. </html>
  2. False
  3. in the console
  4. bright green
  5. an element selector
  6. True
  7. makes it harder
  8. close it, tell an adult
  9. the server sends files
  10. a web server
  11. Yes
  12. 10
  13. #
  14. is for one line of words
  15. 55
  16. screen-reader users
  17. The red kite
  18. yellow
  19. the URL
  20. False
  21. the screen width
  22. <h5>
  23. 3
  24. alt
  25. 2
  26. 4
  27. <h6>
  28. rounds box corners
  29. pink on red
  30. red
  31. <link>
  32. .html
  33. stores a website’s files
  34. No
  35. school.example.in
  36. False
  37. False
  38. bullets
  39. False
  40. on the right

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