← Web development final test lesson New set →

Web Development Worksheet: Final Test

HTML and CSS lesson 30: Web development final test · Set 807 · 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 code links to about.html? (a) <link about.html> (b) <a src="about.html"> (c) <a href="about.html"> (d) <a alt="about.html">
  2. 2.🌈 Which colour is rgb(0, 255, 0)? (a) cyan (b) magenta (c) bright green (d) red
  3. 3.True or false: a code editor shows line numbers. (a) False (b) True
  4. 4.💪 How much empty space (px) is before the first box?
    .row {
      display: flex;
      width: 220px;
      justify-content: center;
    }
    Inside are 2 boxes, each 40px wide (no margins).
  5. 5.Which of these does JavaScript do? (a) changes the text size (b) makes a link (c) puts a picture on a page (d) reacts to a button click
  6. 6.🌗 Is dark grey on white easy or hard to read? (a) hard to read (b) easy to read
  7. 7.🧭 Which semantic tag holds the logo and title? (a) <header> (b) <article> (c) <nav> (d) <footer>
  8. 8.🚀 What is the home page file of a website usually called? (a) index.html (b) main.png (c) home.css (d) start.js
  9. 9.🖼️ Does <img> need a closing tag? (a) Yes (b) No
  10. 10.✍️ What is the selector in this CSS rule?
    #top {
      width: 300px;
      font-style: italic;
    }
    (a) #top (b) italic (c) li (d) width
  11. 11.📱 The screen is 320px wide. What font-size (px) does the paragraph get?
    p {
      font-size: 24px;
    }
    @media (max-width: 600px) {
      p {
        font-size: 22px;
      }
    }
  12. 12.🔒 Is the connection to this address scrambled (encrypted)?
    http://kids.example.org/news/today.html
    (a) Yes (b) No
  13. 13.True or false: #main is a class selector. (a) True (b) False
  14. 14.🔍 Which line is missing its closing tag?
    line 1: <i>Rain today
    line 2: <h2>Good morning!</h2>
    line 3: <u>Cricket is fun.</u>
    (a) line 2 (b) line 3 (c) line 1
  15. 15.🔗 What does HyperText mean? (a) text in colour (b) secret text (c) very big text (d) text with links
  16. 16.🔠 Which heading shows the BIGGEST text: <h1>, <h5>, <h2> or <h4>? (a) <h1> (b) <h5> (c) <h4> (d) <h2>
  17. 17.🚀 Which file should this code go in: alert(score); (a) index.html (b) script.js (c) style.css
  18. 18.What does justify-content: space-between do? (a) equal gaps, none at ends (b) puts boxes in the middle (c) packs boxes at the start (d) packs boxes at the end
  19. 19.🖌️ Which CSS property makes letters bigger? (a) font-weight (b) font-size (c) background-color (d) color
  20. 20.🔁 What does this code print?
    let marks = 25;
    if (marks > 27) {
      console.log("Pass");
    } else {
      console.log("Try again");
    }
    (a) Pass (b) Try again
  21. 21.📝 Which input type lets you pick only one? (a) email (b) date (c) number (d) radio
  22. 22.🖌️ Which CSS property sets the letter colour? (a) font-size (b) font-weight (c) color (d) font-family
  23. 23.⚡ Which tag holds JavaScript in a page? (a) <code> (b) <script> (c) <style> (d) <js>
  24. 24.🏷️ Which is the closing tag for <em>? (a) </em> (b) <em/> (c) <\em> (d) <em>
  25. 25.Which of these goes in the head? (a) <ul> (b) <img> (c) <title> (d) <p>
  26. 26.✍️ Which sign goes between a property and its value? (a) - (b) : (c) = (d) ;
  27. 27.🔠 How many heading levels does HTML have? (a) 4 (b) 10 (c) 6 (d) 3
  28. 28.🖼️ Which attribute of <img> tells which image to load? (a) height (b) alt (c) width (d) src
  29. 29.Which of these is a weak password? (a) Kite_Fl1es@Dawn (b) Mango#Kite29! (c) Blue@Tiger_74 (d) abcd1234
  30. 30.Which of these goes in the head? (a) <img> (b) <h1> (c) <table> (d) <link rel="stylesheet">
  31. 31.Which of these goes in the body? (a) <meta charset="utf-8"> (b) <p> (c) <link rel="stylesheet"> (d) <title>
  32. 32.🔢 In a basic web page file, which comes first: “</head>” or “</html>”? (a) </head> (b) </html>
  33. 33.🔠 Which heading shows the BIGGEST text: <h3>, <h6>, <h5> or <h2>? (a) <h3> (b) <h2> (c) <h6> (d) <h5>
  34. 34.Which colour pair is hard to read? (a) yellow on black (b) light grey on white (c) white on black (d) black on white
  35. 35.💬 Which text will NOT show on the page?
    <p>Good morning!</p>
    <p>The red kite</p>
    <!-- <p>Hello, world!</p> -->
    (a) Good morning! (b) The red kite (c) Hello, world!
  36. 36.💬 Why do coders write comments? (a) to make links (b) to add colour (c) to show pictures (d) to leave notes
  37. 37.🔢 When you open a web page, which comes LAST? (a) the browser shows it (b) the server sends files (c) you type the URL (d) the browser asks it
  38. 38.📋 What number does the browser show next to “Litchi”?
    <ol start="6">
      <li>Jamun</li>
      <li>Grapes</li>
      <li>Litchi</li>
    </ol>
  39. 39.True or false: <nav> helps you move around. (a) False (b) True
  40. 40.🚀 Should file names have spaces, like my page.html? (a) No (b) Yes

Answer key

  1. <a href="about.html">
  2. bright green
  3. True
  4. 70
  5. reacts to a button click
  6. easy to read
  7. <header>
  8. index.html
  9. No
  10. #top
  11. 22
  12. No
  13. False
  14. line 1
  15. text with links
  16. <h1>
  17. script.js
  18. equal gaps, none at ends
  19. font-size
  20. Try again
  21. radio
  22. color
  23. <script>
  24. </em>
  25. <title>
  26. :
  27. 6
  28. src
  29. abcd1234
  30. <link rel="stylesheet">
  31. <p>
  32. </head>
  33. <h2>
  34. light grey on white
  35. Hello, world!
  36. to leave notes
  37. the browser shows it
  38. 8
  39. True
  40. No

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