← Web development final test lesson New set →

Web Development Worksheet: Final Test

HTML and CSS lesson 30: Web development final test · Set 741 · 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.⚡ What number does this code print?
    let coins = 25;
    coins = coins + 9;
    coins = coins - 23;
    console.log(coins);
  2. 2.🧭 Which semantic tag holds copyright notes? (a) <main> (b) <footer> (c) <article> (d) <header>
  3. 3.🔤 In “HTML”, what does the L stand for? (a) Language (b) Link (c) Line (d) Laptop
  4. 4.📦 How much space top to bottom (px) does this box take in all, margin included?
    .box {
      height: 190px;
      padding: 5px;
      border: 1px solid black;
      margin: 20px;
    }
  5. 5.True or false: <p>Hello!</p> goes in index.html. (a) False (b) True
  6. 6.🖌️ Which CSS property sets the letter colour? (a) font-family (b) text-align (c) font-size (d) color
  7. 7.🔠 Which heading shows the SMALLEST text: <h5>, <h1>, <h3> or <h6>? (a) <h5> (b) <h3> (c) <h6> (d) <h1>
  8. 8.🎯 Which CSS selector matches this element?
    <p class="note" id="top">Hello</p>
    (a) #note (b) #top (c) h1 (d) .big
  9. 9.📝 Which tag gives a form box a name you can click? (a) <h1> (b) <hr> (c) <title> (d) <label>
  10. 10.🚀 You change your code. What should you do to see the change? (a) delete the file (b) switch off the PC (c) rename the folder (d) save and refresh
  11. 11.True or false: margin is the line round the box. (a) True (b) False
  12. 12.🔠 Which tag is used for the main title on a page? (a) <br> (b) <h1> (c) <p> (d) <h6>
  13. 13.🌍 What do we call the computer that stores a website? (a) a keyboard (b) a mouse (c) a printer (d) a server
  14. 14.⚖️ What colour is the text of this element?
    <p class="big" id="end">Hi</p>
    CSS:
    p { color: yellow; }
    #end { color: blue; }
    (a) red (b) orange (c) yellow (d) blue
  15. 15.True or false: to share your OTP is not safe. (a) True (b) False
  16. 16.🔒 Is the connection to this address scrambled (encrypted)?
    http://www.example.com/news/today.html
    (a) Yes (b) No
  17. 17.🔁 What does this code print?
    let age = 44;
    if (age < 5) {
      console.log("teen");
    } else {
      console.log("child");
    }
    (a) child (b) teen
  18. 18.🌍 What is the path in this URL?
    http://www.example.com/about.html
    (a) www.example.com (b) /about.html (c) /maths/tables.html (d) http
  19. 19.True or false: <link rel="stylesheet"> goes in the body. (a) False (b) True
  20. 20.📋 How many items does this list show?
    <ul>
      <li>Banana</li>
      <li>Litchi</li>
      <li>Guava</li>
      <li>Mango</li>
      <li>Grapes</li>
      <li>Papaya</li>
    </ul>
  21. 21.📦 In the box model, which part is the gap to other boxes? (a) border (b) content (c) padding (d) margin
  22. 22.📊 Which tag holds the whole table? (a) <table> (b) <caption> (c) <td> (d) <tr>
  23. 23.📱 The screen is 320px wide. What font-size (px) does the paragraph get?
    p {
      font-size: 20px;
    }
    @media (min-width: 480px) {
      p {
        font-size: 24px;
      }
    }
  24. 24.True or false: <input type="email"> lets you pick only one. (a) True (b) False
  25. 25.📋 Does this list show bullets or numbers?
    <ol>
      <li>Papaya</li>
      <li>Mango</li>
    </ol>
    (a) bullets (b) numbers
  26. 26.🧩 Which language makes a form box? (a) CSS (b) HTML (c) JavaScript
  27. 27.🏷️ Every HTML tag starts with which sign? (a) ( (b) < (c) { (d) [
  28. 28.⚡ What does this code show?
    let name = "Meera";
    console.log("Hi, " + name + "!");
    (a) name (b) Meera (c) Hi, Meera! (d) Hi, name!
  29. 29.💪 Which flexbox property picks row or column? (a) justify-content (b) flex-direction (c) gap (d) align-items
  30. 30.🔁 What does this code print?
    let score = 41;
    if (score > 36) {
      console.log("You win");
    } else {
      console.log("Play again");
    }
    (a) Play again (b) You win
  31. 31.Which of these is a strong password? (a) abcd1234 (b) Blue@Tiger_74 (c) 123456 (d) 111111
  32. 32.📄 Where does <style> go: in the head or in the body? (a) in the head (b) in the body
  33. 33.🧭 Why use <nav> instead of <div> for a menu? (a) it tells its meaning (b) it loads faster (c) it makes text red (d) it adds pictures
  34. 34.Which of these is true of a code editor? (a) colours code to help us (b) has an address bar (c) opens web pages for us (d) turns HTML into a page
  35. 35.✍️ In color: blue; which part is the value? (a) ; (b) blue (c) : (d) color
  36. 36.🧱 HTML gives a web page its ___. (a) sound (b) speed (c) colours (d) structure
  37. 37.🎯 Which element does the selector h1 style? (a) <h2> (b) <h1 class="star"> (c) <li class="star"> (d) <div id="top">
  38. 38.🔗 Which address opens when you click this link?
    <a href="quiz.html">Art corner</a>
    (a) games.html (b) Art corner (c) about.html (d) quiz.html
  39. 39.True or false: <li> is an unordered list. (a) True (b) False
  40. 40.🚀 Which tag loads script.js into a page? (a) <a href="script.js"> (b) <script src="script.js"> (c) <js src="script.js"> (d) <link script.js>

Answer key

  1. 11
  2. <footer>
  3. Language
  4. 242
  5. True
  6. color
  7. <h6>
  8. #top
  9. <label>
  10. save and refresh
  11. False
  12. <h1>
  13. a server
  14. blue
  15. True
  16. No
  17. child
  18. /about.html
  19. False
  20. 6
  21. margin
  22. <table>
  23. 20
  24. False
  25. numbers
  26. HTML
  27. <
  28. Hi, Meera!
  29. flex-direction
  30. You win
  31. Blue@Tiger_74
  32. in the head
  33. it tells its meaning
  34. colours code to help us
  35. blue
  36. structure
  37. <h1 class="star">
  38. quiz.html
  39. False
  40. <script src="script.js">

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