← Web development final test lesson New set →

Web Development Worksheet: Final Test

HTML and CSS lesson 30: Web development final test · Set 829 · 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.🖼️ How many pixels wide is the picture drawn?
    <img src="bus.jpg" alt="Our school bus" width="400">
  2. 2.📝 How many paragraphs does this code make?
    <p>Rain today</p>
    <p>Our school trip</p>
    <p>My pets</p>
    <p>Good morning!</p>
    <p>Fun facts</p>
    <h2>Our school trip</h2>
  3. 3.✍️ Which sign ends each CSS declaration? (a) : (b) , (c) ; (d) .
  4. 4.🏷️ Which is the closing tag for <b>? (a) </b> (b) <\b> (c) <b> (d) <b/>
  5. 5.⚖️ What colour is the text of this element?
    <h2 class="star" id="logo">Hi</h2>
    CSS:
    .star { color: white; }
    h2 { color: yellow; }
    #logo { color: blue; }
    (a) blue (b) yellow (c) green (d) white
  6. 6.🧭 How many <main> parts should a page have? (a) one (b) three (c) none (d) ten
  7. 7.⚖️ Which selector is the strongest? (a) an element selector (b) a class selector (c) an id selector
  8. 8.🌈 In #000047 the blue part is the hex number 47. What is it as a normal number?
  9. 9.🔗 Where does this link open?
    <a href="maths.html" target="_blank">School news</a>
    (a) in the same tab (b) in a new tab
  10. 10.🚀 Which file should this code go in: .box { padding: 8px; } (a) script.js (b) index.html (c) style.css
  11. 11.🌍 What is the domain name in this URL?
    http://kids.example.org/index.html
    (a) /index.html (b) school.example.in (c) http (d) kids.example.org
  12. 12.📊 How many heading cells (<th>) does this table have?
    <table>
      <tr><th>Name</th><th>Fruit</th><th>Price</th></tr>
      <tr><td>Grapes</td><td>Banana</td><td>Jamun</td></tr>
      <tr><td>Orange</td><td>Guava</td><td>Papaya</td></tr>
    </table>
  13. 13.🔠 Which heading shows the SMALLEST text: <h4>, <h3>, <h1> or <h2>? (a) <h3> (b) <h4> (c) <h1> (d) <h2>
  14. 14.📝 Which tag makes a drop-down list? (a) <ol> (b) <select> (c) <ul> (d) <li>
  15. 15.🎨 Which attribute adds CSS inside one tag? (a) href (b) src (c) style (d) alt
  16. 16.🌍 Which one scrambles data on its way? (a) the URL (b) the browser (c) the server (d) HTTPS
  17. 17.📱 The screen is 1366px wide. What font-size (px) does the paragraph get?
    p {
      font-size: 20px;
    }
    @media (max-width: 480px) {
      p {
        font-size: 14px;
      }
    }
  18. 18.📦 In the box model, which part is a solid or dotted edge? (a) padding (b) border (c) margin (d) content
  19. 19.📋 What number does the browser show next to “Guava”?
    <ol start="3">
      <li>Jamun</li>
      <li>Papaya</li>
      <li>Orange</li>
      <li>Litchi</li>
      <li>Banana</li>
      <li>Guava</li>
    </ol>
  20. 20.📱 Responsive design means a page ___. (a) never changes (b) fits every screen (c) has no pictures (d) is only for laptops
  21. 21.🔍 Which line is missing its closing tag?
    line 1: <small>I love mangoes.</small>
    line 2: <strong>Fun facts
    line 3: <h2>Hello, world!</h2>
    (a) line 3 (b) line 2 (c) line 1
  22. 22.What does font-size do? (a) makes letters bigger (b) centres a heading (c) sets the letter colour (d) makes the text bold
  23. 23.🌍 Which one is the page’s address? (a) the URL (b) the server (c) HTTPS (d) the browser
  24. 24.🌍 What is the domain name in this URL?
    https://www.example.net/news/today.html
    (a) learn.example.com (b) https (c) /news/today.html (d) www.example.net
  25. 25.🔢 On a typical page, from top to bottom, which comes LAST? (a) <footer> (b) <main> (c) <header> (d) <nav>
  26. 26.📄 What does the browser tab show for this page?
    <!DOCTYPE html>
    <html>
    <head>
      <title>Space Facts</title>
    </head>
    <body>
      <h1>Easy snacks</h1>
      <p>We won by 5 runs.</p>
    </body>
    </html>
    (a) index.html (b) Space Facts (c) We won by 5 runs. (d) Easy snacks
  27. 27.🖼️ Which picture file does the browser load?
    <img src="bus.jpg" alt="Our school bus" width="400">
    (a) bus.jpg (b) tiger.jpg (c) Our school bus (d) fort.jpg
  28. 28.🔤 In “HTML”, what does the M stand for? (a) Machine (b) Markup (c) Mouse (d) Modern
  29. 29.🌈 Which colour is rgb(255, 0, 255)? (a) magenta (b) yellow (c) bright green (d) white
  30. 30.📄 What is the first line of an HTML5 page? (a) <!DOCTYPE html> (b) <body> (c) <html> (d) <head>
  31. 31.🖼️ Which attribute of <img> tells which image to load? (a) height (b) width (c) alt (d) src
  32. 32.🔗 Which address opens when you click this link?
    <a href="games.html">About us</a>
    (a) contact.html (b) games.html (c) about.html (d) About us
  33. 33.📝 What does <hr> draw? (a) a link (b) a table (c) a picture (d) a line across the page
  34. 34.📝 You type 5 spaces between two words in a <p>. How does the browser show them? (a) as a dot (b) as 5 spaces (c) as one space (d) as a new line
  35. 35.📱 What does a media query check? (a) the battery level (b) the time of day (c) the screen width (d) the page title
  36. 36.🔠 Which tag is the least important heading? (a) <h6> (b) <p> (c) <h3> (d) <h1>
  37. 37.True or false: in <img>, alt describes the picture. (a) False (b) True
  38. 38.🌍 Which program shows a web page to us? (a) a web browser (b) a calculator (c) a music player (d) a paint program
  39. 39.🧭 Which semantic tag holds a side box of tips? (a) <header> (b) <aside> (c) <nav> (d) <footer>
  40. 40.⚖️ What colour is the text of this element?
    <h2 class="star" id="main">Hi</h2>
    CSS:
    .star { color: blue; }
    .star { color: orange; }
    (a) blue (b) orange (c) red (d) green

Answer key

  1. 400
  2. 5
  3. ;
  4. </b>
  5. blue
  6. one
  7. an id selector
  8. 71
  9. in a new tab
  10. style.css
  11. kids.example.org
  12. 3
  13. <h4>
  14. <select>
  15. style
  16. HTTPS
  17. 20
  18. border
  19. 8
  20. fits every screen
  21. line 2
  22. makes letters bigger
  23. the URL
  24. www.example.net
  25. <footer>
  26. Space Facts
  27. bus.jpg
  28. Markup
  29. magenta
  30. <!DOCTYPE html>
  31. src
  32. games.html
  33. a line across the page
  34. as one space
  35. the screen width
  36. <h6>
  37. True
  38. a web browser
  39. <aside>
  40. orange

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