← Web development final test lesson New set →

Web Development Worksheet: Final Test

HTML and CSS lesson 30: Web development final test · Set 261 · 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 is the path in this URL?
    https://learn.example.com/games/chess.html
    (a) learn.example.com (b) /games/chess.html (c) /about.html (d) https
  2. 2.📛 In <a href="x.html">, what is href? (a) a comment (b) an attribute (c) an element name (d) a closing tag
  3. 3.💬 How many paragraphs show on the page?
    <p>The red kite</p>
    <p>Hello, world!</p>
    <!-- <p>Fun facts</p> -->
    <p>Good morning!</p>
  4. 4.💪 Which justify-content value packs boxes at the end? (a) flex-end (b) flex-start (c) center (d) space-between
  5. 5.🎯 Which sign starts an id selector? (a) # (b) & (c) @ (d) .
  6. 6.📋 Does this list show bullets or numbers?
    <ul>
      <li>Grapes</li>
      <li>Guava</li>
    </ul>
    (a) bullets (b) numbers
  7. 7.Which of these is a closing tag? (a) <li> (b) </h1> (c) <p> (d) <b>
  8. 8.🔡 Are HTML tag names usually written in small letters? (a) No (b) Yes
  9. 9.🌈 Which colour is rgb(255, 255, 255)? (a) blue (b) bright green (c) white (d) yellow
  10. 10.🎯 How many elements on a page should have the same id? (a) any number (b) 5 (c) 1 (d) 2
  11. 11.⚖️ What colour is the text of this element?
    <h1 class="note" id="logo">Hi</h1>
    CSS:
    h1 { color: yellow; }
    #logo { color: purple; }
    (a) blue (b) purple (c) yellow (d) green
  12. 12.📋 What number does the browser show next to “Banana”?
    <ol start="5">
      <li>Jamun</li>
      <li>Banana</li>
      <li>Orange</li>
    </ol>
  13. 13.📦 How much space across (px) does this box take in all, margin included?
    .box {
      width: 100px;
      padding: 10px;
      border: 2px solid black;
      margin: 20px;
    }
  14. 14.🔍 Which line is missing its closing tag?
    line 1: <u>My pets</u>
    line 2: <p>Rain today</p>
    line 3: <strong>Good morning!
    (a) line 1 (b) line 3 (c) line 2
  15. 15.🌍 Which one is the page’s address? (a) the URL (b) the server (c) the browser (d) HTTPS
  16. 16.💪 How much empty space (px) is left after the last box?
    .row {
      display: flex;
      width: 180px;
      justify-content: flex-start;
    }
    Inside are 2 boxes, each 50px wide (no margins).
  17. 17.🔗 Which code links to about.html? (a) <link about.html> (b) <a href="about.html"> (c) <a src="about.html"> (d) <a alt="about.html">
  18. 18.📋 Which list suits a shopping list in any order? (a) <ul> (b) <ol> (c) <hr> (d) <br>
  19. 19.⚖️ Two rules with the same selector set a colour. Which one wins? (a) neither (b) the first one (c) the shorter one (d) the later one
  20. 20.🌈 In #130000 the red part is the hex number 13. What is it as a normal number?
  21. 21.🌈 Which colour of light is strongest in rgb(185, 134, 99)? (a) blue (b) green (c) red
  22. 22.Which of these is a closing tag? (a) </li> (b) <title> (c) <b> (d) <p>
  23. 23.💬 How many paragraphs show on the page?
    <!-- <p>My best friend</p> -->
    <p>Cricket is fun.</p>
    <p>Hello, world!</p>
  24. 24.🌍 Which one asks for a web page? (a) HTTPS (b) the server (c) the browser (d) the URL
  25. 25.💬 How many paragraphs show on the page?
    <p>My best friend</p>
    <p>Good morning!</p>
    <!-- <p>Fun facts</p> -->
    <p>The red kite</p>
  26. 26.📄 Can HTML on its own show paragraphs? (a) No (b) Yes
  27. 27.True or false: <li> goes inside ul or ol. (a) False (b) True
  28. 28.♿ Is this heading order correct (no level skipped)?
    <h1> → <h3> → <h2> → <h3>
    (a) No (b) Yes
  29. 29.⚡ Which word makes a new variable? (a) put (b) let (c) make (d) give
  30. 30.📝 How many <input> tags are in this form?
    <form>
      <input type="checkbox">
      <input type="date">
      <input type="email">
      <input type="number">
      <input type="submit" value="Send">
    </form>
  31. 31.Which of these is safe to do online? (a) think before you post (b) put secrets in comments (c) post your home address (d) meet an online stranger
  32. 32.📋 Does this list show bullets or numbers?
    <ol>
      <li>Grapes</li>
      <li>Orange</li>
      <li>Banana</li>
    </ol>
    (a) numbers (b) bullets
  33. 33.🌐 Which one answers page requests? (a) a web browser (b) a code editor (c) a web server
  34. 34.🔗 Where does this link open?
    <a href="about.html" target="_blank">Play games</a>
    (a) in a new tab (b) in the same tab
  35. 35.🔠 How many headings are in this code?
    <h1>I love mangoes.</h1>
    <p>Cricket is fun.</p>
    <h2>Rain today</h2>
    <h2>My pets</h2>
    <p>My pets</p>
  36. 36.💬 How does an HTML comment end? (a) // (b) >> (c) */ (d) -->
  37. 37.🧭 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
  38. 38.🖌️ Where does the text sit on its line?
    h1 {
      font-size: 40px;
      color: yellow;
      background-color: green;
      text-align: center;
    }
    (a) on the right (b) on the left (c) in the middle
  39. 39.⚖️ What colour is the text of this element?
    <h2 class="note" id="hero">Hi</h2>
    CSS:
    #hero { color: purple; }
    h2 { color: white; }
    (a) white (b) red (c) purple (d) yellow
  40. 40.Which of these is not safe to do online? (a) use a nickname in games (b) tell a trusted adult (c) think before you post (d) share your password

Answer key

  1. /games/chess.html
  2. an attribute
  3. 3
  4. flex-end
  5. #
  6. bullets
  7. </h1>
  8. Yes
  9. white
  10. 1
  11. purple
  12. 6
  13. 164
  14. line 3
  15. the URL
  16. 80
  17. <a href="about.html">
  18. <ul>
  19. the later one
  20. 19
  21. red
  22. </li>
  23. 2
  24. the browser
  25. 3
  26. Yes
  27. True
  28. No
  29. let
  30. 5
  31. think before you post
  32. numbers
  33. a web server
  34. in a new tab
  35. 3
  36. -->
  37. it tells its meaning
  38. in the middle
  39. purple
  40. share your password

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