← Web development final test lesson New set →

Web Development Worksheet: Final Test

HTML and CSS lesson 30: Web development final test · Set 122 · 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 list suits a shopping list in any order? (a) <hr> (b) <ul> (c) <ol> (d) <br>
  2. 2.🖼️ Which attribute of <img> sets how tall it is? (a) alt (b) height (c) width (d) src
  3. 3.🔒 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
  4. 4.🧭 Why use <nav> instead of <div> for a menu? (a) it makes text red (b) it loads faster (c) it tells its meaning (d) it adds pictures
  5. 5.📄 Can HTML on its own make links to pages? (a) No (b) Yes
  6. 6.🔢 On a typical page, from top to bottom, which comes first: “<main>” or “<header>”? (a) <main> (b) <header>
  7. 7.Which of these is true of <footer>? (a) sits at the bottom (b) is the page’s key part (c) holds one blog post (d) helps you move around
  8. 8.🌍 What is the protocol in this URL?
    http://school.example.in/games/chess.html
    (a) school.example.in (b) http (c) /games/chess.html (d) https
  9. 9.🔁 What does this code print?
    let marks = 15;
    if (marks >= 25) {
      console.log("Pass");
    } else {
      console.log("Try again");
    }
    (a) Try again (b) Pass
  10. 10.🔍 Which is the odd one out? (a) reacts to a button click (b) checks a quiz answer (c) lays out the page (d) counts down a timer
  11. 11.⚡ What does this code show?
    let name = "Meera";
    console.log("Hello, " + name + "!");
    (a) Meera (b) Hello, name! (c) Hello, Meera! (d) name
  12. 12.🖼️ Does <img> need a closing tag? (a) Yes (b) No
  13. 13.💬 Does the browser show comments on the page? (a) Yes (b) No
  14. 14.🚀 Which file is best for the colours and fonts? (a) photo.jpg (b) script.js (c) index.html (d) style.css
  15. 15.🔢 To build and share your first web page, which comes first: “add CSS styles” or “write the HTML”? (a) write the HTML (b) add CSS styles
  16. 16.🧭 Which semantic tag sits at the very top? (a) <nav> (b) <footer> (c) <aside> (d) <header>
  17. 17.♿ Is this heading order correct (no level skipped)?
    <h1> → <h1> → <h2> → <h2>
    (a) No (b) Yes
  18. 18.Which of these does HTML do? (a) checks a quiz answer (b) puts a picture on a page (c) changes the page live (d) reacts to a button click
  19. 19.📱 max-width: 600px applies when the screen is ___. (a) 600px or narrower (b) 600px or wider (c) turned off (d) exactly 1000px
  20. 20.True or false: HTML on its own can pick a random number. (a) True (b) False
  21. 21.🔠 How many heading levels does HTML have? (a) 6 (b) 4 (c) 10 (d) 3
  22. 22.🌈 Which colour of light is strongest in rgb(167, 9, 138)? (a) red (b) blue (c) green
  23. 23.🔗 Which address opens when you click this link?
    <a href="quiz.html">Contact us</a>
    (a) Contact us (b) about.html (c) quiz.html (d) games.html
  24. 24.🌗 Is pink on red easy or hard to read? (a) easy to read (b) hard to read
  25. 25.⚖️ Which selector is the strongest? (a) a class selector (b) an element selector (c) an id selector
  26. 26.Which of these is true of <nav>? (a) helps you move around (b) holds the main content (c) sits at the bottom (d) is the page’s key part
  27. 27.🔠 How many headings are in this code?
    <h1>Our school trip</h1>
    <p>I love mangoes.</p>
    <p>Our school trip</p>
    <p>Good morning!</p>
  28. 28.⚖️ What colour is the text of this element?
    <h2 class="red" id="top">Hi</h2>
    CSS:
    h2 { color: blue; }
    h2 { color: purple; }
    (a) red (b) blue (c) orange (d) purple
  29. 29.📊 Which tag makes one table row? (a) <tr> (b) <th> (c) <table> (d) <caption>
  30. 30.📝 Which input type lets you pick only one? (a) number (b) email (c) radio (d) date
  31. 31.📊 Which tag makes a heading cell? (a) <td> (b) <th> (c) <tr> (d) <table>
  32. 32.📝 Which input type is for an email address? (a) number (b) text (c) submit (d) email
  33. 33.What is <input type="radio"> for? (a) sends the form (b) lets you tick many (c) picks a day (d) lets you pick only one
  34. 34.🌈 Which colour of light is strongest in rgb(219, 134, 4)? (a) green (b) red (c) blue
  35. 35.🎯 Which element does the selector .big style? (a) <span id="big"> (b) <p class="box"> (c) <span class="big"> (d) <span class="red">
  36. 36.📄 What is the big heading shown on this page?
    <!DOCTYPE html>
    <html>
    <head>
      <title>Space Facts</title>
    </head>
    <body>
      <h1>Match report</h1>
      <p>We won by 5 runs.</p>
    </body>
    </html>
    (a) Match report (b) Space Facts (c) We won by 5 runs. (d) body
  37. 37.📝 Which input type hides what you type? (a) number (b) checkbox (c) password (d) radio
  38. 38.🏷️ Is <p> an opening tag or a closing tag? (a) an opening tag (b) a closing tag
  39. 39.✍️ What is the selector in this CSS rule?
    p {
      padding: 8px;
      margin: 10px;
      font-style: italic;
      font-weight: bold;
    }
    (a) padding (b) p (c) 10px (d) .note
  40. 40.⚖️ What colour is the text of this element?
    <h2 class="star" id="top">Hi</h2>
    CSS:
    h2 { color: orange; }
    #top { color: white; }
    .star { color: blue; }
    (a) blue (b) orange (c) white (d) black

Answer key

  1. <ul>
  2. height
  3. the data is scrambled
  4. it tells its meaning
  5. Yes
  6. <header>
  7. sits at the bottom
  8. http
  9. Try again
  10. lays out the page
  11. Hello, Meera!
  12. No
  13. No
  14. style.css
  15. write the HTML
  16. <header>
  17. Yes
  18. puts a picture on a page
  19. 600px or narrower
  20. False
  21. 6
  22. red
  23. quiz.html
  24. hard to read
  25. an id selector
  26. helps you move around
  27. 1
  28. purple
  29. <tr>
  30. radio
  31. <th>
  32. email
  33. lets you pick only one
  34. red
  35. <span class="big">
  36. Match report
  37. password
  38. an opening tag
  39. p
  40. white

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