← Colours: hex and rgb lesson New set →

CSS Worksheet: Hex and RGB Colours

HTML and CSS lesson 15: Colours: hex and rgb · Set 117 · 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) white (b) yellow (c) blue (d) red
  2. 2.🌈 Which hex code is red? (a) #ffffff (b) #000000 (c) #ff0000 (d) #00ff00
  3. 3.🌈 Which colour is #00ff00? (a) blue (b) cyan (c) bright green (d) magenta
  4. 4.🌈 Hex digits go 0 to 9, then A to which letter? (a) Z (b) G (c) F (d) J
  5. 5.🌈 In #rrggbb, which colour do the last two digits give? (a) green (b) white (c) red (d) blue
  6. 6.🌈 How many pairs of hex digits are in a colour like #ff8800? (a) 2 (b) 6 (c) 4 (d) 3
  7. 7.🌈 In #rrggbb, which colour do the first two digits give? (a) black (b) red (c) blue (d) green
  8. 8.🌈 Which hex code is magenta? (a) #ffffff (b) #ff00ff (c) #00ff00 (d) #0000ff
  9. 9.🌈 Which colour is #000000? (a) magenta (b) bright green (c) red (d) black
  10. 10.🌈 Which colour is rgb(255, 0, 255)? (a) yellow (b) black (c) red (d) magenta
  11. 11.🌈 Which hex code is blue? (a) #ff00ff (b) #00ffff (c) #0000ff (d) #00ff00
  12. 12.🌈 Which colour is #ff0000? (a) red (b) bright green (c) blue (d) black
  13. 13.🌈 In #007300 the green part is the hex number 73. What is it as a normal number?
  14. 14.🌈 Which colour of light is strongest in rgb(106, 165, 74)? (a) blue (b) green (c) red
  15. 15.🌈 Which colour of light is strongest in rgb(209, 87, 9)? (a) red (b) green (c) blue
  16. 16.🌈 In #00001b the blue part is the hex number 1b. What is it as a normal number?
  17. 17.🌈 In #d90000 the red part is the hex number d9. What is it as a normal number?
  18. 18.🌈 Which colour of light is strongest in rgb(80, 152, 32)? (a) green (b) blue (c) red
  19. 19.🌈 Which colour is #ffff00? (a) magenta (b) blue (c) white (d) yellow
  20. 20.🌈 Which hex code is yellow? (a) #00ffff (b) #ffff00 (c) #ff0000 (d) #00ff00
  21. 21.🌈 Which colour is #00ffff? (a) blue (b) magenta (c) cyan (d) bright green
  22. 22.🌈 Which hex code is white? (a) #ff00ff (b) #ffffff (c) #00ff00 (d) #ffff00
  23. 23.🌈 Which colour of light is strongest in rgb(52, 161, 6)? (a) blue (b) red (c) green
  24. 24.🌈 Which colour is rgb(0, 0, 0)? (a) cyan (b) bright green (c) black (d) red
  25. 25.🌈 Which colour of light is strongest in rgb(254, 97, 79)? (a) blue (b) red (c) green
  26. 26.🌈 Which colour of light is strongest in rgb(68, 93, 224)? (a) blue (b) red (c) green
  27. 27.🌈 Which colour is #ff00ff? (a) blue (b) white (c) cyan (d) magenta
  28. 28.🌈 Which colour of light is strongest in rgb(37, 182, 2)? (a) red (b) blue (c) green
  29. 29.🌈 Which colour of light is strongest in rgb(135, 20, 195)? (a) red (b) blue (c) green
  30. 30.🌈 Which colour of light is strongest in rgb(164, 3, 115)? (a) red (b) green (c) blue
  31. 31.🌈 What is the biggest number one colour can have in rgb()? (a) 1000 (b) 255 (c) 99 (d) 100
  32. 32.🌈 Which colour is rgb(255, 0, 0)? (a) white (b) red (c) black (d) cyan
  33. 33.🌈 In #000083 the blue part is the hex number 83. What is it as a normal number?
  34. 34.🌈 Which colour is rgb(255, 255, 0)? (a) black (b) red (c) blue (d) yellow
  35. 35.🌈 Which colour of light is strongest in rgb(222, 116, 29)? (a) green (b) red (c) blue
  36. 36.🌈 Which colour is rgb(0, 0, 255)? (a) blue (b) magenta (c) yellow (d) black
  37. 37.🌈 Which colour of light is strongest in rgb(26, 46, 228)? (a) blue (b) green (c) red
  38. 38.🌈 Which colour of light is strongest in rgb(233, 59, 98)? (a) green (b) red (c) blue
  39. 39.🌈 Which colour is rgb(255, 255, 255)? (a) white (b) black (c) blue (d) red
  40. 40.🌈 In #a90000 the red part is the hex number a9. What is it as a normal number?

Answer key

  1. blue
  2. #ff0000
  3. bright green
  4. F
  5. blue
  6. 3
  7. red
  8. #ff00ff
  9. black
  10. magenta
  11. #0000ff
  12. red
  13. 115
  14. green
  15. red
  16. 27
  17. 217
  18. green
  19. yellow
  20. #ffff00
  21. cyan
  22. #ffffff
  23. green
  24. black
  25. red
  26. blue
  27. magenta
  28. green
  29. blue
  30. red
  31. 255
  32. red
  33. 131
  34. yellow
  35. red
  36. blue
  37. blue
  38. red
  39. white
  40. 169

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