← Web development final test lesson New set →

Web Development Worksheet: Final Test

HTML and CSS lesson 30: Web development final test · Set 288 · 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 one sends pages over the net? (a) a code editor (b) a web browser (c) a web server
  2. 2.📝 What does <hr> draw? (a) a picture (b) a table (c) a link (d) a line across the page
  3. 3.True or false: HTML on its own can make links to pages. (a) True (b) False
  4. 4.🧭 Which semantic tag sits at the bottom? (a) <header> (b) <footer> (c) <article> (d) <aside>
  5. 5.🔁 How many times does this code print “Well done”?
    for (let i = 2; i < 11; i++) {
      console.log("Well done");
    }
  6. 6.True or false: in <img>, width sets how wide it is. (a) False (b) True
  7. 7.🔠 How many headings are in this code?
    <h1>Cricket is fun.</h1>
    <h4>Fun facts</h4>
    <h3>Rain today</h3>
  8. 8.🌍 What finds the server for a domain name like example.com? (a) CSS (b) DNS (c) alt (d) HTML
  9. 9.🌈 Hex digits go 0 to 9, then A to which letter? (a) Z (b) F (c) G (d) J
  10. 10.⚡ Which JavaScript word makes a new variable? (a) if (b) alert() (c) console.log() (d) let
  11. 11.♿ Does this help everyone, or make the page harder to use: tiny grey text? (a) helps everyone (b) makes it harder
  12. 12.Which of these is padding? (a) the text or picture (b) space outside the border (c) the gap round content (d) the line round the box
  13. 13.⚖️ Two rules with the same selector set a colour. Which one wins? (a) neither (b) the first one (c) the shorter one (d) the later one
  14. 14.📱 The screen is 540px wide. Does the rule inside @media apply?
    p {
      font-size: 12px;
    }
    @media (min-width: 480px) {
      p {
        font-size: 14px;
      }
    }
    (a) Yes (b) No
  15. 15.🔠 Which heading shows the SMALLEST text: <h3>, <h6>, <h5> or <h2>? (a) <h3> (b) <h2> (c) <h6> (d) <h5>
  16. 16.True or false: <p>Hello!</p> goes in index.html. (a) False (b) True
  17. 17.🔁 Which loop repeats code a set number of times? (a) if (b) else (c) let (d) for
  18. 18.🏷️ Is </title> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
  19. 19.Which of these is the content? (a) the line round the box (b) the text or picture (c) the gap to other boxes (d) the gap round content
  20. 20.🎯 Which CSS selector matches this element?
    <h1 class="note" id="main">Hello</h1>
    (a) .big (b) #note (c) #logo (d) .note
  21. 21.🖼️ Why do we add alt text to an image? (a) to make it bigger (b) to colour it (c) to describe the image (d) to load it faster
  22. 22.🌈 Which hex code is white? (a) #ffffff (b) #000000 (c) #00ff00 (d) #0000ff
  23. 23.🔒 What does the lock (HTTPS) in the address bar mean? (a) the site is free (b) the site is a game (c) the data is scrambled (d) the site is fast
  24. 24.📝 Which input type sends the form? (a) submit (b) number (c) checkbox (d) email
  25. 25.🚀 Which file should this code go in: alert(score); (a) script.js (b) style.css (c) index.html
  26. 26.True or false: “use headings in order” makes the page harder to use. (a) True (b) False
  27. 27.🛡️ Online: is it safe to share your password? (a) safe (b) not safe
  28. 28.⚖️ Which selector is the strongest? (a) an element selector (b) an id selector (c) a class selector
  29. 29.📦 How much space top to bottom (px) does this box take in all, margin included?
    .box {
      height: 90px;
      padding: 10px;
      border: 2px solid black;
      margin: 0px;
    }
  30. 30.True or false: a code editor shows line numbers. (a) True (b) False
  31. 31.🎯 Which CSS selector matches this element?
    <div class="box" id="main">Hello</div>
    (a) .star (b) .main (c) div (d) #box
  32. 32.🔗 Which words do you click on?
    <a href="art.html">Art corner</a>
    (a) School news (b) Art corner (c) art.html (d) href
  33. 33.🎯 Which CSS selector matches this element?
    <h1 class="note" id="end">Hello</h1>
    (a) .note (b) .end (c) #hero (d) #note
  34. 34.🔢 In a basic web page file, which comes FIRST? (a) </head> (b) </body> (c) <body> (d) <!DOCTYPE html>
  35. 35.📊 Which tag makes one table row? (a) <table> (b) <caption> (c) <tr> (d) <td>
  36. 36.Which of these goes in the body? (a) <meta charset="utf-8"> (b) <style> (c) <ul> (d) <title>
  37. 37.✍️ CSS declarations go inside which brackets? (a) [ ] (b) < > (c) { } (d) ( )
  38. 38.📄 Can HTML on its own make tables? (a) No (b) Yes
  39. 39.🔡 Are HTML tag names usually written in small letters? (a) Yes (b) No
  40. 40.⚡ Which tag holds JavaScript in a page? (a) <style> (b) <script> (c) <js> (d) <code>

Answer key

  1. a web server
  2. a line across the page
  3. True
  4. <footer>
  5. 9
  6. True
  7. 3
  8. DNS
  9. F
  10. let
  11. makes it harder
  12. the gap round content
  13. the later one
  14. Yes
  15. <h6>
  16. True
  17. for
  18. a closing tag
  19. the text or picture
  20. .note
  21. to describe the image
  22. #ffffff
  23. the data is scrambled
  24. submit
  25. script.js
  26. False
  27. not safe
  28. an id selector
  29. 114
  30. True
  31. div
  32. Art corner
  33. .note
  34. <!DOCTYPE html>
  35. <tr>
  36. <ul>
  37. { }
  38. Yes
  39. Yes
  40. <script>

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