← Web development final test lesson New set →

Web Development Worksheet: Final Test

HTML and CSS lesson 30: Web development final test · Set 629 · 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 colour is #000000? (a) black (b) magenta (c) cyan (d) blue
  2. 2.🔠 How many headings are in this code?
    <h1>My best friend</h1>
    <p>Cricket is fun.</p>
    <p>Rain today</p>
    <h2>I love mangoes.</h2>
    <p>Our school trip</p>
  3. 3.🔠 Which tag is the least important heading? (a) <h3> (b) <p> (c) <h1> (d) <h6>
  4. 4.🌈 In #003a00 the green part is the hex number 3a. What is it as a normal number?
  5. 5.🔍 Which is the odd one out? (a) is where we type code (b) stores a website’s files (c) hosts websites online (d) sends pages over the net
  6. 6.True or false: CSS shows a pop-up message. (a) True (b) False
  7. 7.🎨 One CSS file can style how many pages? (a) only one word (b) only one image (c) many pages (d) no pages
  8. 8.🔐 Is Rain#Drop_42! a strong or a weak password? (a) weak (b) strong
  9. 9.💪 Which justify-content value equal gaps, none at ends? (a) flex-start (b) space-between (c) center (d) flex-end
  10. 10.⚡ What does alert() show? (a) a table (b) a picture (c) a new tab (d) a pop-up box
  11. 11.🖼️ How many pixels wide is the picture drawn?
    <img src="map.png" alt="Map of India" width="150">
  12. 12.🌍 Which one shows the page to you? (a) the URL (b) HTTPS (c) the browser (d) the server
  13. 13.📱 The screen is 1100px wide. Does the rule inside @media apply?
    p {
      font-size: 20px;
    }
    @media (min-width: 480px) {
      p {
        font-size: 22px;
      }
    }
    (a) No (b) Yes
  14. 14.🖼️ How many pixels wide is the picture drawn?
    <img src="moon.png" alt="The full moon" width="200">
  15. 15.True or false: img is an id selector. (a) True (b) False
  16. 16.Which of these is an opening tag? (a) </p> (b) </b> (c) <b> (d) </title>
  17. 17.🚀 Which file should this code go in: console.log(5 + 2); (a) style.css (b) index.html (c) script.js
  18. 18.True or false: HTML on its own cannot make tables. (a) False (b) True
  19. 19.📝 How many <input> tags are in this form?
    <form>
      <input type="email">
      <input type="number">
      <input type="submit" value="Send">
    </form>
  20. 20.♿ Does this help everyone, or make the page harder to use: add alt text to images? (a) makes it harder (b) helps everyone
  21. 21.🎯 What kind of selector is img? (a) an id selector (b) a class selector (c) an element selector
  22. 22.🔢 In a basic web page file, which comes LAST? (a) </html> (b) <html> (c) </head> (d) <body>
  23. 23.True or false: <a> goes in the head. (a) True (b) False
  24. 24.🔢 To build and share your first web page, which comes first: “plan what to show” or “add CSS styles”? (a) add CSS styles (b) plan what to show
  25. 25.⚡ Which JavaScript word writes in the console? (a) let (b) console.log() (c) alert() (d) for
  26. 26.📊 In a table, which tag is a row? (a) <tr> (b) <tb> (c) <th> (d) <td>
  27. 27.Which of these goes in the head? (a) <a> (b) <style> (c) <ul> (d) <img>
  28. 28.🔢 When you open a web page, which comes first: “DNS finds the server” or “the browser shows it”? (a) the browser shows it (b) DNS finds the server
  29. 29.📊 How many heading cells (<th>) does this table have?
    <table>
      <tr><th>Name</th><th>Fruit</th></tr>
      <tr><td>Papaya</td><td>Jamun</td></tr>
    </table>
  30. 30.🔢 When you open a web page, which comes first: “you type the URL” or “DNS finds the server”? (a) you type the URL (b) DNS finds the server
  31. 31.🔁 How many times does this code print “Welcome”?
    for (let i = 2; i < 6; i++) {
      console.log("Welcome");
    }
  32. 32.📊 How many heading cells (<th>) does this table have?
    <table>
      <tr><th>Name</th><th>Fruit</th><th>Price</th></tr>
      <tr><td>Mango</td><td>Papaya</td><td>Litchi</td></tr>
      <tr><td>Guava</td><td>Mango</td><td>Litchi</td></tr>
      <tr><td>Papaya</td><td>Orange</td><td>Jamun</td></tr>
    </table>
  33. 33.📝 On how many lines does the browser show this paragraph?
    <p>Birds sing<br>Sky is blue<br>Roses are red<br>Kites fly high</p>
  34. 34.🎯 Which CSS selector matches this element?
    <p class="star" id="hero">Hello</p>
    (a) #top (b) h1 (c) p (d) #star
  35. 35.📦 How much space across (px) does this box take in all, margin included?
    .box {
      width: 130px;
      padding: 10px;
      border: 4px solid black;
      margin: 5px;
    }
  36. 36.Which of these has a closing tag? (a) <b> (b) <input> (c) <img> (d) <br>
  37. 37.🛡️ Online: is it safe to meet an online stranger? (a) not safe (b) safe
  38. 38.Which of these is a strong password? (a) password (b) 123456 (c) abcd1234 (d) Chai$Cup_19x
  39. 39.Which of these goes in the head? (a) <h1> (b) <ul> (c) <meta charset="utf-8"> (d) <p>
  40. 40.True or false: h1 is an id selector. (a) False (b) True

Answer key

  1. black
  2. 2
  3. <h6>
  4. 58
  5. is where we type code
  6. False
  7. many pages
  8. strong
  9. space-between
  10. a pop-up box
  11. 150
  12. the browser
  13. Yes
  14. 200
  15. False
  16. <b>
  17. script.js
  18. False
  19. 3
  20. helps everyone
  21. an element selector
  22. </html>
  23. False
  24. plan what to show
  25. console.log()
  26. <tr>
  27. <style>
  28. DNS finds the server
  29. 2
  30. you type the URL
  31. 4
  32. 3
  33. 4
  34. p
  35. 168
  36. <b>
  37. not safe
  38. Chai$Cup_19x
  39. <meta charset="utf-8">
  40. False

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