← Colours: hex and rgb lesson New set →

CSS Worksheet: Hex and RGB Colours

HTML and CSS lesson 15: Colours: hex and rgb · Set 27 · 40 questions
TalentJR

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. 1.🌈 Which colour is #0000ff? (a) cyan (b) yellow (c) bright green (d) blue
  2. 2.🌈 Which colour of light is strongest in rgb(45, 196, 78)? (a) blue (b) red (c) green
  3. 3.🌈 Which colour is #ffff00? (a) blue (b) yellow (c) red (d) black
  4. 4.🌈 In #000057 the blue part is the hex number 57. What is it as a normal number?
  5. 5.🌈 Which colour of light is strongest in rgb(197, 115, 113)? (a) red (b) green (c) blue
  6. 6.🌈 In #330000 the red part is the hex number 33. What is it as a normal number?
  7. 7.🌈 Which colour is #00ff00? (a) bright green (b) cyan (c) white (d) blue
  8. 8.🌈 In #rrggbb, which colour do the first two digits give? (a) black (b) red (c) green (d) blue
  9. 9.🌈 How many pairs of hex digits are in a colour like #ff8800? (a) 2 (b) 6 (c) 4 (d) 3
  10. 10.🌈 Which colour is rgb(255, 255, 255)? (a) blue (b) white (c) magenta (d) black
  11. 11.🌈 Which colour is rgb(0, 0, 255)? (a) magenta (b) cyan (c) yellow (d) blue
  12. 12.🌈 In #000073 the blue part is the hex number 73. What is it as a normal number?
  13. 13.🌈 In #00f100 the green part is the hex number f1. What is it as a normal number?
  14. 14.🌈 Which hex code is blue? (a) #00ff00 (b) #00ffff (c) #0000ff (d) #ffff00
  15. 15.🌈 Which colour is #ffffff? (a) white (b) bright green (c) yellow (d) cyan
  16. 16.🌈 In #rrggbb, which colour do the last two digits give? (a) white (b) green (c) red (d) blue
  17. 17.🌈 Hex digits go 0 to 9, then A to which letter? (a) Z (b) G (c) F (d) J
  18. 18.🌈 Which colour is rgb(0, 0, 0)? (a) blue (b) yellow (c) cyan (d) black
  19. 19.🌈 Which colour of light is strongest in rgb(104, 89, 178)? (a) blue (b) red (c) green
  20. 20.🌈 Which colour of light is strongest in rgb(107, 8, 180)? (a) red (b) blue (c) green
  21. 21.🌈 Which hex code is black? (a) #ff0000 (b) #000000 (c) #ffffff (d) #ffff00
  22. 22.🌈 Which colour is rgb(0, 255, 0)? (a) blue (b) magenta (c) black (d) bright green
  23. 23.🌈 Which hex code is yellow? (a) #ff0000 (b) #ffff00 (c) #ffffff (d) #ff00ff
  24. 24.🌈 Which colour is #00ffff? (a) yellow (b) white (c) cyan (d) magenta
  25. 25.🌈 Which hex code is bright green? (a) #ff0000 (b) #ffff00 (c) #000000 (d) #00ff00
  26. 26.🌈 Which colour is #ff0000? (a) bright green (b) magenta (c) cyan (d) red
  27. 27.🌈 Which colour of light is strongest in rgb(94, 183, 140)? (a) blue (b) green (c) red
  28. 28.🌈 In #00007c the blue part is the hex number 7c. What is it as a normal number?
  29. 29.🌈 Which colour is #000000? (a) yellow (b) white (c) black (d) cyan
  30. 30.🌈 In #0000c4 the blue part is the hex number c4. What is it as a normal number?
  31. 31.🌈 Which colour of light is strongest in rgb(166, 19, 9)? (a) green (b) red (c) blue
  32. 32.🌈 Which colour of light is strongest in rgb(172, 3, 8)? (a) green (b) blue (c) red
  33. 33.🌈 Which hex code is red? (a) #00ffff (b) #00ff00 (c) #ff0000 (d) #ff00ff
  34. 34.🌈 What is the biggest number one colour can have in rgb()? (a) 1000 (b) 99 (c) 255 (d) 100
  35. 35.🌈 Which colour is rgb(255, 0, 255)? (a) yellow (b) cyan (c) white (d) magenta
  36. 36.🌈 In #00002a the blue part is the hex number 2a. What is it as a normal number?
  37. 37.🌈 Which colour is rgb(255, 0, 0)? (a) yellow (b) red (c) bright green (d) blue
  38. 38.🌈 In #00fe00 the green part is the hex number fe. What is it as a normal number?
  39. 39.🌈 In #00006f the blue part is the hex number 6f. What is it as a normal number?
  40. 40.🌈 In #000099 the blue part is the hex number 99. What is it as a normal number?

Answer key

  1. blue
  2. green
  3. yellow
  4. 87
  5. red
  6. 51
  7. bright green
  8. red
  9. 3
  10. white
  11. blue
  12. 115
  13. 241
  14. #0000ff
  15. white
  16. blue
  17. F
  18. black
  19. blue
  20. blue
  21. #000000
  22. bright green
  23. #ffff00
  24. cyan
  25. #00ff00
  26. red
  27. green
  28. 124
  29. black
  30. 196
  31. red
  32. red
  33. #ff0000
  34. 255
  35. magenta
  36. 42
  37. red
  38. 254
  39. 111
  40. 153

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