CSS Worksheet: Hex and RGB Colours
Code tip (Red, green, blue): rgb(red, green, blue): each from 0 to 255. #rrggbb: the same three numbers in hex. Hex digits: 0–9, then a = 10, b = 11, c = 12, d = 13, e = 14, f = 15. A pair = 16 × first digit + second digit: ff = 16 × 15 + 15 = 255.
NameDateTime takenScore ___ / 40
- 1.🌈 Which colour of light is strongest in rgb(69, 159, 8)? (a) green (b) blue (c) red
- 2.🌈 Which colour is #ff0000? (a) white (b) red (c) bright green (d) black
- 3.🌈 What is the biggest number one colour can have in rgb()? (a) 99 (b) 255 (c) 100 (d) 1000
- 4.🌈 Which colour of light is strongest in rgb(0, 203, 17)? (a) red (b) blue (c) green
- 5.🌈 Which colour is #00ffff? (a) white (b) black (c) red (d) cyan
- 6.🌈 In #830000 the red part is the hex number 83. What is it as a normal number?
- 7.🌈 In #rrggbb, which colour do the first two digits give? (a) blue (b) green (c) black (d) red
- 8.🌈 In #0b0000 the red part is the hex number 0b. What is it as a normal number?
- 9.🌈 Which colour is rgb(255, 255, 0)? (a) yellow (b) black (c) white (d) blue
- 10.🌈 How many pairs of hex digits are in a colour like #ff8800? (a) 2 (b) 4 (c) 6 (d) 3
- 11.🌈 In #rrggbb, which colour do the last two digits give? (a) green (b) blue (c) white (d) red
- 12.🌈 In #980000 the red part is the hex number 98. What is it as a normal number?
- 13.🌈 Which hex code is bright green? (a) #00ff00 (b) #00ffff (c) #ffff00 (d) #ff0000
- 14.🌈 Hex digits go 0 to 9, then A to which letter? (a) J (b) G (c) F (d) Z
- 15.🌈 Which colour is rgb(255, 0, 0)? (a) magenta (b) black (c) white (d) red
- 16.🌈 Which colour is #000000? (a) cyan (b) black (c) magenta (d) white
- 17.🌈 Which hex code is blue? (a) #0000ff (b) #ff00ff (c) #000000 (d) #00ffff
- 18.🌈 In #0000a8 the blue part is the hex number a8. What is it as a normal number?
- 19.🌈 Which colour of light is strongest in rgb(17, 8, 234)? (a) blue (b) red (c) green
- 20.🌈 Which colour of light is strongest in rgb(43, 161, 58)? (a) red (b) blue (c) green
- 21.🌈 Which colour is rgb(255, 0, 255)? (a) magenta (b) bright green (c) black (d) cyan
- 22.🌈 Which hex code is black? (a) #000000 (b) #ffffff (c) #0000ff (d) #00ff00
- 23.🌈 Which colour is #ffff00? (a) yellow (b) red (c) blue (d) white
- 24.🌈 In #3e0000 the red part is the hex number 3e. What is it as a normal number?
- 25.🌈 Which colour is rgb(0, 0, 255)? (a) cyan (b) blue (c) magenta (d) bright green
- 26.🌈 Which colour is rgb(0, 255, 255)? (a) red (b) cyan (c) magenta (d) black
- 27.🌈 Which colour of light is strongest in rgb(156, 40, 27)? (a) green (b) red (c) blue
- 28.🌈 Which colour of light is strongest in rgb(78, 3, 162)? (a) red (b) blue (c) green
- 29.🌈 Which colour is #00ff00? (a) yellow (b) white (c) bright green (d) cyan
- 30.🌈 Which colour is #ffffff? (a) white (b) yellow (c) cyan (d) blue
- 31.🌈 Which colour is rgb(255, 255, 255)? (a) white (b) black (c) red (d) yellow
- 32.🌈 In #000005 the blue part is the hex number 05. What is it as a normal number?
- 33.🌈 Which colour of light is strongest in rgb(66, 191, 132)? (a) blue (b) green (c) red
- 34.🌈 Which colour is rgb(0, 255, 0)? (a) black (b) bright green (c) white (d) red
- 35.🌈 Which hex code is white? (a) #ffff00 (b) #000000 (c) #ffffff (d) #00ffff
- 36.🌈 In #008a00 the green part is the hex number 8a. What is it as a normal number?
- 37.🌈 Which colour of light is strongest in rgb(88, 41, 195)? (a) red (b) green (c) blue
- 38.🌈 Which hex code is red? (a) #00ff00 (b) #ff00ff (c) #00ffff (d) #ff0000
- 39.🌈 Which colour of light is strongest in rgb(22, 14, 205)? (a) red (b) blue (c) green
- 40.🌈 Which colour is rgb(0, 0, 0)? (a) black (b) magenta (c) cyan (d) blue
Answer key
- green
- red
- 255
- green
- cyan
- 131
- red
- 11
- yellow
- 3
- blue
- 152
- #00ff00
- F
- red
- black
- #0000ff
- 168
- blue
- green
- magenta
- #000000
- yellow
- 62
- blue
- cyan
- red
- blue
- bright green
- white
- white
- 5
- green
- bright green
- #ffffff
- 138
- blue
- #ff0000
- blue
- black
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids