← Web development final test lesson New set →

Web Development Worksheet: Final Test

HTML and CSS lesson 30: Web development final test · Set 179 · 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.📄 What is the first line of an HTML5 page? (a) <html> (b) <head> (c) <body> (d) <!DOCTYPE html>
  2. 2.⚡ Which JavaScript word writes in the console? (a) if (b) let (c) alert() (d) console.log()
  3. 3.💬 Which text will NOT show on the page?
    <!-- <p>Cricket is fun.</p> -->
    <p>Our school trip</p>
    <p>Hello, world!</p>
    (a) Hello, world! (b) Our school trip (c) Cricket is fun.
  4. 4.💬 Why do coders write comments? (a) to show pictures (b) to add colour (c) to leave notes (d) to make links
  5. 5.True or false: <b> is an empty tag. (a) False (b) True
  6. 6.📋 Which list tag lists steps in order? (a) <ol> (b) <li> (c) <ul>
  7. 7.🎯 Can many elements share the same class? (a) No (b) Yes
  8. 8.🌍 What does a web address (URL) tell the browser? (a) your password (b) the page colour (c) how old you are (d) where the page is
  9. 9.Which of these goes in the body? (a) <title> (b) <meta charset="utf-8"> (c) <link rel="stylesheet"> (d) <h1>
  10. 10.True or false: a web browser turns HTML into a page. (a) True (b) False
  11. 11.🎯 Which element does the selector .big style? (a) <h2 id="big"> (b) <h2 class="big"> (c) <li class="box"> (d) <h2 class="red">
  12. 12.⚖️ What colour is the text of this element?
    <h1 class="big" id="intro">Hi</h1>
    CSS:
    #intro { color: blue; }
    #intro { color: purple; }
    (a) black (b) orange (c) purple (d) blue
  13. 13.Which colour pair is easy to read? (a) yellow on white (b) white on dark blue (c) pink on red (d) red on green
  14. 14.🔠 Which heading shows the BIGGEST text: <h6>, <h5>, <h2> or <h1>? (a) <h2> (b) <h6> (c) <h1> (d) <h5>
  15. 15.⚖️ Which selector is the strongest? (a) an element selector (b) an id selector (c) a class selector
  16. 16.📝 Which input type sends the form? (a) submit (b) checkbox (c) date (d) number
  17. 17.🎯 What kind of selector is .menu? (a) an element selector (b) an id selector (c) a class selector
  18. 18.✍️ How many declarations (property: value pairs) are in this rule?
    h1 {
      background-color: yellow;
      border: 2px solid;
    }
  19. 19.♿ Who uses a screen reader? (a) people who are blind (b) only teachers (c) only robots (d) only coders
  20. 20.✍️ Which property is set to 8px in this rule?
    #top {
      margin: 10px;
      padding: 8px;
    }
    (a) font-weight (b) padding (c) 8px (d) border
  21. 21.Which of these does JavaScript do? (a) makes headings and lists (b) rounds box corners (c) reacts to a button click (d) makes a link
  22. 22.🖼️ Which picture file does the browser load?
    <img src="tiger.jpg" alt="A tiger asleep" width="300">
    (a) map.png (b) tiger.jpg (c) kite.png (d) A tiger asleep
  23. 23.True or false: to tell a trusted adult is safe. (a) True (b) False
  24. 24.🧩 Which language rounds box corners? (a) HTML (b) CSS (c) JavaScript
  25. 25.💪 How much empty space (px) is before the first box?
    .row {
      display: flex;
      width: 380px;
      justify-content: flex-end;
    }
    Inside are 3 boxes, each 100px wide (no margins).
  26. 26.What does justify-content: center do? (a) puts boxes in the middle (b) packs boxes at the start (c) packs boxes at the end (d) equal gaps, none at ends
  27. 27.🌈 Which colour is rgb(0, 0, 255)? (a) red (b) yellow (c) magenta (d) blue
  28. 28.🎨 Which tag holds CSS inside the head? (a) <script> (b) <css> (c) <style> (d) <body>
  29. 29.💬 How many paragraphs show on the page?
    <p>Hello, world!</p>
    <!-- <p>Fun facts</p> -->
    <p>My best friend</p>
  30. 30.🔗 Which address opens when you click this link?
    <a href="art.html">Contact us</a>
    (a) Contact us (b) news.html (c) art.html (d) quiz.html
  31. 31.Which of these is true of <article>? (a) sits at the very top (b) holds one blog post (c) holds the menu of links (d) holds the main content
  32. 32.📄 Can HTML on its own add pictures to a page? (a) Yes (b) No
  33. 33.🖼️ The picture cannot load. Which text does the browser show instead?
    <img src="kite.png" alt="A red kite" width="50">
    (a) kite.png (b) A red kite (c) Map of India (d) width
  34. 34.💬 How many paragraphs show on the page?
    <!-- <p>I love mangoes.</p> -->
    <!-- <p>Our school trip</p> -->
    <p>Hello, world!</p>
  35. 35.📋 Which list shows the steps of a recipe best? (a) <br> (b) <hr> (c) <ul> (d) <ol>
  36. 36.🔗 Which address opens when you click this link?
    <a href="contact.html">Take the quiz</a>
    (a) contact.html (b) https://example.com (c) Take the quiz (d) maths.html
  37. 37.🌗 Is yellow on white easy or hard to read? (a) easy to read (b) hard to read
  38. 38.🔍 Which line is missing its closing tag?
    line 1: <em>Cricket is fun.</em>
    line 2: <h2>My pets
    line 3: <u>My best friend</u>
    (a) line 3 (b) line 1 (c) line 2
  39. 39.🌍 What is the path in this URL?
    http://school.example.in/games/chess.html
    (a) http (b) school.example.in (c) /about.html (d) /games/chess.html
  40. 40.🌍 What is the path in this URL?
    http://learn.example.com/maths/tables.html
    (a) /index.html (b) http (c) /maths/tables.html (d) learn.example.com

Answer key

  1. <!DOCTYPE html>
  2. console.log()
  3. Cricket is fun.
  4. to leave notes
  5. False
  6. <ol>
  7. Yes
  8. where the page is
  9. <h1>
  10. True
  11. <h2 class="big">
  12. purple
  13. white on dark blue
  14. <h1>
  15. an id selector
  16. submit
  17. a class selector
  18. 2
  19. people who are blind
  20. padding
  21. reacts to a button click
  22. tiger.jpg
  23. True
  24. CSS
  25. 80
  26. puts boxes in the middle
  27. blue
  28. <style>
  29. 2
  30. art.html
  31. holds one blog post
  32. Yes
  33. A red kite
  34. 1
  35. <ol>
  36. contact.html
  37. hard to read
  38. line 2
  39. /games/chess.html
  40. /maths/tables.html

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