← Colour and text properties lesson New set →

CSS Worksheet: Colour and Text Properties

HTML and CSS lesson 14: Colour and text properties · Set 135 · 40 questions
TalentJR

Code tip (Letters, behind, size, place): color = colour of the letters; background-color = colour behind them. font-size = how big (e.g. 20px); font-weight: bold = thick letters; font-family = the font. text-align: left / center / right places the text on its line.

NameDateTime takenScore ___ / 40
  1. 1.🖌️ What colour are the letters?
    h1 {
      text-align: left;
      background-color: orange;
      color: black;
      font-size: 12px;
    }
    (a) yellow (b) black (c) orange
  2. 2.🖌️ What colour are the letters?
    p {
      color: orange;
      font-size: 12px;
      text-align: center;
      background-color: blue;
    }
    (a) green (b) orange (c) blue
  3. 3.🖌️ What colour is behind the letters?
    h1 {
      font-size: 24px;
      color: yellow;
      text-align: center;
      background-color: red;
    }
    (a) red (b) blue (c) yellow
  4. 4.What does background-color do? (a) picks the font style (b) makes letters bigger (c) makes the text bold (d) colours behind the text
  5. 5.🖌️ What colour is behind the letters?
    p {
      background-color: white;
      color: purple;
      text-align: right;
      font-size: 12px;
    }
    (a) white (b) green (c) purple
  6. 6.What does color do? (a) picks the font style (b) colours behind the text (c) makes the text bold (d) sets the letter colour
  7. 7.🖌️ What colour is behind the letters?
    h1 {
      background-color: red;
      color: green;
      text-align: left;
      font-size: 32px;
    }
    (a) red (b) white (c) green
  8. 8.🖌️ What colour are the letters?
    h1 {
      text-align: left;
      background-color: yellow;
      font-size: 12px;
      color: orange;
    }
    (a) green (b) yellow (c) orange
  9. 9.🖌️ What colour is behind the letters?
    p {
      text-align: center;
      background-color: purple;
      font-size: 20px;
      color: yellow;
    }
    (a) yellow (b) blue (c) purple
  10. 10.🖌️ Where does the text sit on its line?
    h2 {
      color: white;
      font-size: 20px;
      background-color: purple;
      text-align: left;
    }
    (a) on the left (b) on the right (c) in the middle
  11. 11.🖌️ What colour is behind the letters?
    h2 {
      color: green;
      text-align: right;
      font-size: 12px;
      background-color: white;
    }
    (a) green (b) white (c) purple
  12. 12.🖌️ What colour are the letters?
    p {
      font-size: 24px;
      text-align: left;
      color: green;
      background-color: red;
    }
    (a) white (b) green (c) red
  13. 13.🖌️ What colour is behind the letters?
    li {
      background-color: orange;
      text-align: center;
      font-size: 24px;
      color: red;
    }
    (a) red (b) purple (c) orange
  14. 14.🖌️ Which CSS property colours behind the text? (a) font-size (b) background-color (c) font-weight (d) color
  15. 15.🖌️ What colour is behind the letters?
    h2 {
      background-color: orange;
      font-size: 16px;
      color: blue;
      text-align: right;
    }
    (a) blue (b) orange (c) green
  16. 16.🖌️ What colour are the letters?
    li {
      text-align: left;
      background-color: black;
      font-size: 16px;
      color: blue;
    }
    (a) black (b) blue (c) red
  17. 17.🖌️ What colour is behind the letters?
    h2 {
      font-size: 40px;
      text-align: right;
      background-color: blue;
      color: red;
    }
    (a) red (b) blue (c) white
  18. 18.🖌️ What colour are the letters?
    li {
      font-size: 16px;
      background-color: purple;
      text-align: left;
      color: yellow;
    }
    (a) black (b) purple (c) yellow
  19. 19.What does text-align do? (a) sets the letter colour (b) centres a heading (c) colours behind the text (d) picks the font style
  20. 20.🖌️ How big is the text, in px?
    p {
      background-color: yellow;
      text-align: center;
      font-size: 40px;
      color: red;
    }
  21. 21.🖌️ How big is the text, in px?
    h1 {
      background-color: orange;
      text-align: right;
      color: yellow;
      font-size: 32px;
    }
  22. 22.🖌️ How big is the text, in px?
    p {
      color: orange;
      text-align: right;
      font-size: 36px;
      background-color: blue;
    }
  23. 23.What does font-weight do? (a) colours behind the text (b) sets the letter colour (c) makes the text bold (d) makes letters bigger
  24. 24.🖌️ What colour are the letters?
    li {
      text-align: left;
      color: yellow;
      background-color: white;
      font-size: 16px;
    }
    (a) white (b) blue (c) yellow
  25. 25.🖌️ What colour are the letters?
    li {
      background-color: white;
      text-align: left;
      color: black;
      font-size: 20px;
    }
    (a) white (b) purple (c) black
  26. 26.🖌️ What colour are the letters?
    h2 {
      color: black;
      text-align: left;
      font-size: 16px;
      background-color: blue;
    }
    (a) blue (b) white (c) black
  27. 27.What does font-family do? (a) colours behind the text (b) makes the text bold (c) sets the letter colour (d) picks the font style
  28. 28.🖌️ How big is the text, in px?
    li {
      font-size: 36px;
      background-color: yellow;
      color: blue;
      text-align: left;
    }
  29. 29.🖌️ What colour are the letters?
    h2 {
      background-color: orange;
      text-align: center;
      color: black;
      font-size: 32px;
    }
    (a) orange (b) black (c) white
  30. 30.🖌️ What colour are the letters?
    h2 {
      text-align: center;
      color: white;
      background-color: red;
      font-size: 40px;
    }
    (a) orange (b) red (c) white
  31. 31.What does font-size do? (a) makes letters bigger (b) colours behind the text (c) makes the text bold (d) centres a heading
  32. 32.🖌️ What colour are the letters?
    p {
      background-color: yellow;
      color: white;
      font-size: 40px;
      text-align: right;
    }
    (a) red (b) yellow (c) white
  33. 33.🖌️ Where does the text sit on its line?
    h2 {
      font-size: 16px;
      background-color: orange;
      color: yellow;
      text-align: center;
    }
    (a) on the left (b) on the right (c) in the middle
  34. 34.🖌️ What colour are the letters?
    p {
      font-size: 12px;
      background-color: yellow;
      text-align: center;
      color: white;
    }
    (a) yellow (b) purple (c) white
  35. 35.🖌️ What colour are the letters?
    h2 {
      color: yellow;
      text-align: left;
      font-size: 40px;
      background-color: blue;
    }
    (a) blue (b) yellow (c) orange
  36. 36.🖌️ What colour is behind the letters?
    p {
      text-align: right;
      font-size: 12px;
      background-color: green;
      color: purple;
    }
    (a) blue (b) purple (c) green
  37. 37.🖌️ Which CSS property makes letters bigger? (a) background-color (b) color (c) font-family (d) font-size
  38. 38.🖌️ What colour are the letters?
    h1 {
      text-align: center;
      color: blue;
      font-size: 20px;
      background-color: purple;
    }
    (a) purple (b) blue (c) yellow
  39. 39.🖌️ Where does the text sit on its line?
    p {
      text-align: left;
      background-color: green;
      font-size: 20px;
      color: purple;
    }
    (a) on the right (b) in the middle (c) on the left
  40. 40.🖌️ What colour is behind the letters?
    li {
      color: blue;
      background-color: green;
      text-align: right;
      font-size: 32px;
    }
    (a) blue (b) green (c) purple

Answer key

  1. black
  2. orange
  3. red
  4. colours behind the text
  5. white
  6. sets the letter colour
  7. red
  8. orange
  9. purple
  10. on the left
  11. white
  12. green
  13. orange
  14. background-color
  15. orange
  16. blue
  17. blue
  18. yellow
  19. centres a heading
  20. 40
  21. 32
  22. 36
  23. makes the text bold
  24. yellow
  25. black
  26. black
  27. picks the font style
  28. 36
  29. black
  30. white
  31. makes letters bigger
  32. white
  33. in the middle
  34. white
  35. yellow
  36. green
  37. font-size
  38. blue
  39. on the left
  40. green

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