← Web development final test lesson New set →

Web Development Worksheet: Final Test

HTML and CSS lesson 30: Web development final test · Set 321 · 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 colour is #ff00ff? (a) bright green (b) magenta (c) white (d) blue
  2. 2.🔍 Which is the odd one out? (a) gives the page structure (b) adds space around boxes (c) makes a link (d) makes headings and lists
  3. 3.🔐 Is riya2014 a strong or a weak password? (a) weak (b) strong
  4. 4.🔁 How many numbers does this code print?
    for (let i = 0; i < 19; i = i + 3) {
      console.log(i);
    }
  5. 5.🔗 Which words do you click on?
    <a href="quiz.html">Play games</a>
    (a) About us (b) Play games (c) quiz.html (d) href
  6. 6.🌗 Is black on white easy or hard to read? (a) hard to read (b) easy to read
  7. 7.Which of these has a closing tag? (a) <img> (b) <b> (c) <br> (d) <hr>
  8. 8.🎨 A CSS file usually ends with which extension? (a) .html (b) .png (c) .js (d) .css
  9. 9.⚖️ What colour is the text of this element?
    <h2 class="box" id="intro">Hi</h2>
    CSS:
    .box { color: green; }
    .box { color: orange; }
    (a) red (b) orange (c) white (d) green
  10. 10.True or false: to put secrets in comments is safe. (a) True (b) False
  11. 11.♿ Who uses a screen reader? (a) only robots (b) only teachers (c) only coders (d) people who are blind
  12. 12.True or false: “images with no alt” helps everyone use the page. (a) False (b) True
  13. 13.📦 How much space across (px) does this box take in all, margin included?
    .box {
      width: 260px;
      padding: 10px;
      border: 3px solid black;
      margin: 10px;
    }
  14. 14.⚡ A JavaScript file usually ends with which extension? (a) .html (b) .jpg (c) .js (d) .css
  15. 15.True or false: <meta> has a closing tag. (a) False (b) True
  16. 16.🔢 In a basic web page file, which comes first: “</html>” or “<html>”? (a) <html> (b) </html>
  17. 17.Which of these is true of <header>? (a) holds a side box of tips (b) holds the logo and title (c) sits at the bottom (d) is the page’s key part
  18. 18.⚖️ What colour is the text of this element?
    <h2 class="red" id="top">Hi</h2>
    CSS:
    .red { color: green; }
    h2 { color: blue; }
    (a) purple (b) green (c) orange (d) blue
  19. 19.📱 The screen is 540px wide. What font-size (px) does the paragraph get?
    p {
      font-size: 24px;
    }
    @media (min-width: 600px) {
      p {
        font-size: 28px;
      }
    }
  20. 20.📋 How many items does this list show?
    <ul>
      <li>Mango</li>
      <li>Jamun</li>
      <li>Papaya</li>
      <li>Grapes</li>
      <li>Guava</li>
    </ul>
  21. 21.🌈 In #000066 the blue part is the hex number 66. What is it as a normal number?
  22. 22.🧭 Which semantic tag holds one blog post? (a) <nav> (b) <aside> (c) <article> (d) <footer>
  23. 23.True or false: the server scrambles data on its way. (a) False (b) True
  24. 24.🌐 Which one saves our .html files? (a) a code editor (b) a web server (c) a web browser
  25. 25.True or false: the border is the line round the box. (a) False (b) True
  26. 26.🌈 In #960000 the red part is the hex number 96. What is it as a normal number?
  27. 27.What does color do? (a) makes letters bigger (b) makes the text bold (c) centres a heading (d) sets the letter colour
  28. 28.💬 Why do coders write comments? (a) to show pictures (b) to leave notes (c) to make links (d) to add colour
  29. 29.🌈 Which colour is rgb(255, 0, 0)? (a) yellow (b) blue (c) bright green (d) red
  30. 30.True or false: in <img>, src shows if the image fails. (a) True (b) False
  31. 31.🔗 Where does this link open?
    <a href="games.html" target="_blank">Contact us</a>
    (a) in the same tab (b) in a new tab
  32. 32.✍️ What is the selector in this CSS rule?
    h1 {
      margin: 10px;
      width: 300px;
    }
    (a) 300px (b) h1 (c) margin (d) p
  33. 33.🧭 How many <main> parts should a page have? (a) three (b) one (c) none (d) ten
  34. 34.🔍 Which is the odd one out? (a) sends pages over the net (b) opens web pages for us (c) answers page requests (d) stores a website’s files
  35. 35.True or false: in <img>, alt describes the picture. (a) True (b) False
  36. 36.💬 How many paragraphs show on the page?
    <!-- <p>Hello, world!</p> -->
    <p>The red kite</p>
    <p>Cricket is fun.</p>
  37. 37.🔢 On a typical page, from top to bottom, which comes LAST? (a) <main> (b) <header> (c) <footer> (d) <nav>
  38. 38.📱 What does a media query check? (a) the time of day (b) the battery level (c) the screen width (d) the page title
  39. 39.📦 How much space top to bottom (px) does this box take in all, margin included?
    .box {
      height: 100px;
      padding: 30px;
      border: 3px solid black;
      margin: 10px;
    }
  40. 40.📊 How many heading cells (<th>) does this table have?
    <table>
      <tr><th>Name</th><th>Fruit</th><th>Price</th></tr>
      <tr><td>Guava</td><td>Banana</td><td>Mango</td></tr>
      <tr><td>Guava</td><td>Mango</td><td>Banana</td></tr>
      <tr><td>Grapes</td><td>Jamun</td><td>Litchi</td></tr>
    </table>

Answer key

  1. magenta
  2. adds space around boxes
  3. weak
  4. 7
  5. Play games
  6. easy to read
  7. <b>
  8. .css
  9. orange
  10. False
  11. people who are blind
  12. False
  13. 306
  14. .js
  15. False
  16. <html>
  17. holds the logo and title
  18. green
  19. 24
  20. 5
  21. 102
  22. <article>
  23. False
  24. a code editor
  25. True
  26. 150
  27. sets the letter colour
  28. to leave notes
  29. red
  30. False
  31. in a new tab
  32. h1
  33. one
  34. opens web pages for us
  35. True
  36. 2
  37. <footer>
  38. the screen width
  39. 186
  40. 3

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