← Colour and text properties lesson New set →

CSS Worksheet: Colour and Text Properties

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

Answer key

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

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