← Web development final test lesson New set →

Web Development Worksheet: Final Test

HTML and CSS lesson 30: Web development final test · Set 264 · 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 of these goes in the head? (a) <style> (b) <ul> (c) <table> (d) <h1>
  2. 2.True or false: body { margin: 0; } goes in style.css. (a) False (b) True
  3. 3.True or false: JavaScript changes the text size. (a) False (b) True
  4. 4.🧭 Is <span> semantic or not semantic? (a) not semantic (b) semantic
  5. 5.📄 Can HTML on its own run a game loop? (a) Yes (b) No
  6. 6.📝 Does <h1> have a closing tag, or is it an empty tag? (a) has a closing tag (b) an empty tag
  7. 7.🔠 How many headings are in this code?
    <h1>I love mangoes.</h1>
    <p>My best friend</p>
    <p>My best friend</p>
  8. 8.True or false: <li> is an unordered list. (a) True (b) False
  9. 9.True or false: JavaScript puts a picture on a page. (a) False (b) True
  10. 10.Which of these does HTML do? (a) gives the page structure (b) sets colours and fonts (c) changes the text size (d) reacts to a button click
  11. 11.What does justify-content: flex-start do? (a) packs boxes at the end (b) equal gaps, none at ends (c) puts boxes in the middle (d) packs boxes at the start
  12. 12.🔍 One closing tag is missing. Which one?
    <b>My pets</b>
    <u>Hello, world!
    <h3>Cricket is fun.</h3>
    (a) </h2> (b) </b> (c) </u> (d) </h3>
  13. 13.✍️ What value is given to font-size in this rule?
    .box {
      font-size: 20px;
      background-color: yellow;
      margin: 10px;
    }
    (a) font-size (b) 20px (c) center (d) yellow
  14. 14.🔢 On a typical page, from top to bottom, which comes LAST? (a) <header> (b) <main> (c) <nav> (d) <footer>
  15. 15.🖌️ Where does the text sit on its line?
    h1 {
      background-color: purple;
      font-size: 40px;
      text-align: left;
      color: yellow;
    }
    (a) on the left (b) on the right (c) in the middle
  16. 16.Which of these goes in the body? (a) <title> (b) <table> (c) <style> (d) <meta charset="utf-8">
  17. 17.⚡ What number does this code print?
    let coins = 30;
    coins = coins + 2;
    coins = coins - 16;
    console.log(coins);
  18. 18.True or false: body is an id selector. (a) False (b) True
  19. 19.📋 Which list tag lists steps in order? (a) <ul> (b) <ol> (c) <li>
  20. 20.📋 Which list tag lists things in any order? (a) <ul> (b) <ol> (c) <li>
  21. 21.🖼️ Which attribute of <img> sets how tall it is? (a) src (b) height (c) width (d) alt
  22. 22.🔠 Which heading shows the BIGGEST text: <h2>, <h6>, <h4> or <h1>? (a) <h1> (b) <h6> (c) <h2> (d) <h4>
  23. 23.🔗 Which address opens when you click this link?
    <a href="about.html">Contact us</a>
    (a) Contact us (b) https://example.com (c) contact.html (d) about.html
  24. 24.🔠 Which heading shows the BIGGEST text: <h4>, <h3>, <h1> or <h6>? (a) <h3> (b) <h6> (c) <h4> (d) <h1>
  25. 25.Which of these is true of <footer>? (a) holds the logo and title (b) holds extra side notes (c) sits at the bottom (d) is the page’s key part
  26. 26.🔢 To build and share your first web page, which comes first: “publish it online” or “write the HTML”? (a) write the HTML (b) publish it online
  27. 27.📝 How many paragraphs does this code make?
    <p>I love mangoes.</p>
    <p>My best friend</p>
    <h2>The red kite</h2>
  28. 28.🖼️ The picture cannot load. Which text does the browser show instead?
    <img src="cake.jpg" alt="Birthday cake" width="150">
    (a) cake.jpg (b) width (c) Birthday cake (d) A happy dog
  29. 29.🌗 Is blue on purple easy or hard to read? (a) hard to read (b) easy to read
  30. 30.True or false: h1 { font-size: 32px; } goes in index.html. (a) True (b) False
  31. 31.🧭 Is <main> semantic or not semantic? (a) not semantic (b) semantic
  32. 32.Which of these is safe to do online? (a) meet an online stranger (b) post your home address (c) keep passwords secret (d) share your password
  33. 33.📝 Which input type takes only numbers? (a) date (b) checkbox (c) number (d) password
  34. 34.🔁 How many numbers does this code print?
    for (let i = 0; i < 19; i = i + 3) {
      console.log(i);
    }
  35. 35.📝 You type 5 spaces between two words in a <p>. How does the browser show them? (a) as 5 spaces (b) as one space (c) as a dot (d) as a new line
  36. 36.True or false: HTML makes a form box. (a) False (b) True
  37. 37.True or false: <title> goes in the body. (a) True (b) False
  38. 38.🛡️ Online: is it safe to ask before downloading? (a) safe (b) not safe
  39. 39.🔠 Which heading shows the SMALLEST text: <h6>, <h1>, <h4> or <h5>? (a) <h6> (b) <h4> (c) <h1> (d) <h5>
  40. 40.Which colour pair is easy to read? (a) yellow on white (b) pink on red (c) white on black (d) red on green

Answer key

  1. <style>
  2. True
  3. False
  4. not semantic
  5. No
  6. has a closing tag
  7. 1
  8. False
  9. False
  10. gives the page structure
  11. packs boxes at the start
  12. </u>
  13. 20px
  14. <footer>
  15. on the left
  16. <table>
  17. 16
  18. False
  19. <ol>
  20. <ul>
  21. height
  22. <h1>
  23. about.html
  24. <h1>
  25. sits at the bottom
  26. write the HTML
  27. 2
  28. Birthday cake
  29. hard to read
  30. False
  31. semantic
  32. keep passwords secret
  33. number
  34. 7
  35. as one space
  36. True
  37. False
  38. safe
  39. <h6>
  40. white on black

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