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 is rgb(255, 0, 0)? (a) white (b) red (c) magenta (d) cyan
- 2.🌈 Which colour is #000000? (a) cyan (b) magenta (c) blue (d) black
- 3.🌈 Which colour is rgb(0, 255, 0)? (a) bright green (b) blue (c) red (d) yellow
- 4.🌈 In #100000 the red part is the hex number 10. What is it as a normal number?
- 5.🌈 What is the biggest number one colour can have in rgb()? (a) 100 (b) 99 (c) 255 (d) 1000
- 6.🌈 Which colour of light is strongest in rgb(201, 62, 21)? (a) red (b) green (c) blue
- 7.🌈 Which colour is #0000ff? (a) black (b) blue (c) bright green (d) white
- 8.🌈 In #rrggbb, which colour do the last two digits give? (a) red (b) green (c) white (d) blue
- 9.🌈 Which colour of light is strongest in rgb(193, 19, 105)? (a) blue (b) red (c) green
- 10.🌈 Which colour is rgb(0, 0, 255)? (a) red (b) blue (c) magenta (d) cyan
- 11.🌈 Which colour of light is strongest in rgb(159, 15, 138)? (a) blue (b) green (c) red
- 12.🌈 Which colour of light is strongest in rgb(15, 200, 111)? (a) blue (b) red (c) green
- 13.🌈 Which hex code is yellow? (a) #ff00ff (b) #ffff00 (c) #00ffff (d) #00ff00
- 14.🌈 Which colour of light is strongest in rgb(79, 211, 133)? (a) blue (b) red (c) green
- 15.🌈 Which colour of light is strongest in rgb(162, 78, 74)? (a) red (b) green (c) blue
- 16.🌈 In #rrggbb, which colour do the first two digits give? (a) blue (b) green (c) red (d) black
- 17.🌈 In #090000 the red part is the hex number 09. What is it as a normal number?
- 18.🌈 Which colour of light is strongest in rgb(52, 54, 212)? (a) red (b) green (c) blue
- 19.🌈 Which colour is rgb(255, 255, 255)? (a) cyan (b) white (c) red (d) yellow
- 20.🌈 Which colour is rgb(255, 0, 255)? (a) blue (b) magenta (c) red (d) white
- 21.🌈 In #300000 the red part is the hex number 30. What is it as a normal number?
- 22.🌈 Which colour of light is strongest in rgb(170, 45, 139)? (a) blue (b) red (c) green
- 23.🌈 Which colour of light is strongest in rgb(204, 3, 76)? (a) blue (b) red (c) green
- 24.🌈 Which colour is rgb(0, 255, 255)? (a) black (b) white (c) magenta (d) cyan
- 25.🌈 How many pairs of hex digits are in a colour like #ff8800? (a) 2 (b) 3 (c) 6 (d) 4
- 26.🌈 Which colour of light is strongest in rgb(77, 190, 31)? (a) blue (b) green (c) red
- 27.🌈 Which hex code is blue? (a) #000000 (b) #ffff00 (c) #00ffff (d) #0000ff
- 28.🌈 Which colour is #ffff00? (a) yellow (b) bright green (c) white (d) black
- 29.🌈 Which colour is #ff00ff? (a) magenta (b) black (c) yellow (d) red
- 30.🌈 Which colour of light is strongest in rgb(189, 40, 57)? (a) green (b) red (c) blue
- 31.🌈 Which colour of light is strongest in rgb(78, 189, 17)? (a) blue (b) red (c) green
- 32.🌈 Which hex code is bright green? (a) #000000 (b) #00ff00 (c) #0000ff (d) #00ffff
- 33.🌈 Which colour of light is strongest in rgb(128, 36, 180)? (a) green (b) blue (c) red
- 34.🌈 Hex digits go 0 to 9, then A to which letter? (a) J (b) F (c) G (d) Z
- 35.🌈 In #000034 the blue part is the hex number 34. What is it as a normal number?
- 36.🌈 Which hex code is red? (a) #00ff00 (b) #000000 (c) #ff0000 (d) #00ffff
- 37.🌈 Which colour is #ff0000? (a) magenta (b) yellow (c) red (d) blue
- 38.🌈 Which colour is #ffffff? (a) white (b) black (c) cyan (d) magenta
- 39.🌈 In #500000 the red part is the hex number 50. What is it as a normal number?
- 40.🌈 Which colour of light is strongest in rgb(19, 190, 17)? (a) blue (b) red (c) green
Answer key
- red
- black
- bright green
- 16
- 255
- red
- blue
- blue
- red
- blue
- red
- green
- #ffff00
- green
- red
- red
- 9
- blue
- white
- magenta
- 48
- red
- red
- cyan
- 3
- green
- #0000ff
- yellow
- magenta
- red
- green
- #00ff00
- blue
- F
- 52
- #ff0000
- red
- white
- 80
- green
Free html and css lessons, practice and worksheets at talentjr.in/html-css-for-kids