← Web development final test lesson New set →

Web Development Worksheet: Final Test

HTML and CSS lesson 30: Web development final test · Set 336 · 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 sign starts a class selector? (a) . (b) # (c) @ (d) &
  2. 2.🔗 What does target="_blank" do to a link? (a) opens it in a new tab (b) makes it blank (c) makes it bold (d) hides the link
  3. 3.True or false: to post your home address is safe. (a) False (b) True
  4. 4.🎨 A CSS file usually ends with which extension? (a) .css (b) .html (c) .js (d) .png
  5. 5.📝 What does <hr> draw? (a) a link (b) a table (c) a picture (d) a line across the page
  6. 6.⚡ What does JavaScript add to a web page? (a) the domain name (b) actions and changes (c) the page title (d) only colours
  7. 7.💬 Which text will NOT show on the page?
    <!-- <p>Rain today</p> -->
    <p>Cricket is fun.</p>
    <p>My best friend</p>
    <p>Our school trip</p>
    (a) Rain today (b) My best friend (c) Cricket is fun. (d) Our school trip
  8. 8.True or false: #hero is an element selector. (a) True (b) False
  9. 9.True or false: h1 { font-size: 32px; } goes in script.js. (a) True (b) False
  10. 10.🔠 How many heading levels does HTML have? (a) 10 (b) 3 (c) 4 (d) 6
  11. 11.📦 How much space across (px) does this box take in all, margin included?
    .box {
      width: 260px;
      padding: 25px;
      border: 5px solid black;
      margin: 20px;
    }
  12. 12.True or false: HTML on its own cannot add up two numbers. (a) False (b) True
  13. 13.🔢 To build and share your first web page, what comes right after “plan what to show”? (a) test in a browser (b) add CSS styles (c) write the HTML (d) publish it online
  14. 14.🔗 Which words do you click on?
    <a href="about.html">Play games</a>
    (a) Play games (b) about.html (c) href (d) About us
  15. 15.Which of these is the border? (a) the gap round content (b) the gap to other boxes (c) a solid or dotted edge (d) the text or picture
  16. 16.🌍 What is the path in this URL?
    http://school.example.in/index.html
    (a) /art/gallery.html (b) /index.html (c) school.example.in (d) http
  17. 17.🔠 How many headings are in this code?
    <h1>Our school trip</h1>
    <p>My best friend</p>
    <h4>Cricket is fun.</h4>
  18. 18.📄 Which part holds everything you see on the page? (a) the head (b) the body (c) the title (d) the doctype
  19. 19.Which of these is an opening tag? (a) <body> (b) </h1> (c) </p> (d) </title>
  20. 20.📝 On how many lines does the browser show this paragraph?
    <p>Birds sing<br>Roses are red</p>
  21. 21.🖼️ Which picture file does the browser load?
    <img src="tiger.jpg" alt="A tiger asleep" width="100">
    (a) A tiger asleep (b) tiger.jpg (c) map.png (d) kite.png
  22. 22.🏷️ Which is the closing tag for <b>? (a) <b/> (b) <\b> (c) <b> (d) </b>
  23. 23.🌈 How many pairs of hex digits are in a colour like #ff8800? (a) 6 (b) 3 (c) 2 (d) 4
  24. 24.💪 How much empty space (px) is before the first box?
    .row {
      display: flex;
      width: 180px;
      justify-content: center;
    }
    Inside are 2 boxes, each 50px wide (no margins).
  25. 25.♿ Is this heading order correct (no level skipped)?
    <h1> → <h1> → <h2> → <h2>
    (a) Yes (b) No
  26. 26.🌈 Which colour is rgb(255, 255, 255)? (a) blue (b) white (c) bright green (d) black
  27. 27.📦 In the box model, which part is a solid or dotted edge? (a) border (b) padding (c) content (d) margin
  28. 28.🔢 On a typical page, from top to bottom, which comes first: “<header>” or “<footer>”? (a) <footer> (b) <header>
  29. 29.🖌️ What colour is behind the letters?
    h1 {
      text-align: left;
      background-color: red;
      font-size: 32px;
      color: purple;
    }
    (a) purple (b) green (c) red
  30. 30.📝 What does <br> do? (a) adds a picture (b) starts a new line (c) makes text bold (d) makes a list
  31. 31.📋 What number does the browser show next to “Banana”?
    <ol start="8">
      <li>Mango</li>
      <li>Papaya</li>
      <li>Grapes</li>
      <li>Jamun</li>
      <li>Orange</li>
      <li>Banana</li>
    </ol>
  32. 32.Which of these is true of a web server? (a) turns HTML into a page (b) saves our .html files (c) has an address bar (d) answers page requests
  33. 33.📱 max-width: 600px applies when the screen is ___. (a) turned off (b) 600px or narrower (c) 600px or wider (d) exactly 1000px
  34. 34.💬 Can anyone read your comments by viewing the page source? (a) Yes (b) No
  35. 35.🧩 Which language changes the text size? (a) CSS (b) JavaScript (c) HTML
  36. 36.🔠 Which heading shows the BIGGEST text: <h5>, <h3>, <h1> or <h2>? (a) <h3> (b) <h1> (c) <h2> (d) <h5>
  37. 37.♿ A part of the page is under a <h2> heading. Which tag should its sub-heading use? (a) <h3> (b) <h4> (c) <h1> (d) <h6>
  38. 38.🌍 What do we call the computer that stores a website? (a) a mouse (b) a keyboard (c) a server (d) a printer
  39. 39.🎨 Which tag holds CSS inside the head? (a) <css> (b) <body> (c) <script> (d) <style>
  40. 40.🔁 When does the else part run? (a) always (b) never (c) when if is false (d) when if is true

Answer key

  1. .
  2. opens it in a new tab
  3. False
  4. .css
  5. a line across the page
  6. actions and changes
  7. Rain today
  8. False
  9. False
  10. 6
  11. 360
  12. True
  13. write the HTML
  14. Play games
  15. a solid or dotted edge
  16. /index.html
  17. 2
  18. the body
  19. <body>
  20. 2
  21. tiger.jpg
  22. </b>
  23. 3
  24. 40
  25. Yes
  26. white
  27. border
  28. <header>
  29. red
  30. starts a new line
  31. 13
  32. answers page requests
  33. 600px or narrower
  34. Yes
  35. CSS
  36. <h1>
  37. <h3>
  38. a server
  39. <style>
  40. when if is false

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