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