← Colours: hex and rgb lesson New set →

CSS Worksheet: Hex and RGB Colours

HTML and CSS lesson 15: Colours: hex and rgb · Set 184 · 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 of light is strongest in rgb(126, 233, 5)? (a) red (b) blue (c) green
  2. 2.🌈 Which colour is rgb(255, 255, 255)? (a) yellow (b) bright green (c) red (d) white
  3. 3.🌈 In #rrggbb, which colour do the first two digits give? (a) blue (b) green (c) red (d) black
  4. 4.🌈 Which hex code is cyan? (a) #0000ff (b) #000000 (c) #00ffff (d) #ff00ff
  5. 5.🌈 Which colour of light is strongest in rgb(100, 65, 169)? (a) blue (b) red (c) green
  6. 6.🌈 Which colour is #00ffff? (a) magenta (b) yellow (c) cyan (d) bright green
  7. 7.🌈 What is the biggest number one colour can have in rgb()? (a) 1000 (b) 99 (c) 255 (d) 100
  8. 8.🌈 In #rrggbb, which colour do the last two digits give? (a) blue (b) green (c) white (d) red
  9. 9.🌈 Which colour is rgb(255, 0, 255)? (a) white (b) red (c) black (d) magenta
  10. 10.🌈 Which colour of light is strongest in rgb(123, 20, 172)? (a) green (b) blue (c) red
  11. 11.🌈 Which colour of light is strongest in rgb(47, 119, 204)? (a) red (b) green (c) blue
  12. 12.🌈 In #004500 the green part is the hex number 45. What is it as a normal number?
  13. 13.🌈 How many pairs of hex digits are in a colour like #ff8800? (a) 4 (b) 2 (c) 3 (d) 6
  14. 14.🌈 Which colour is rgb(0, 0, 255)? (a) yellow (b) black (c) blue (d) red
  15. 15.🌈 Which colour is #ffff00? (a) bright green (b) white (c) yellow (d) blue
  16. 16.🌈 Which colour of light is strongest in rgb(128, 102, 255)? (a) green (b) blue (c) red
  17. 17.🌈 Which colour is #ffffff? (a) cyan (b) white (c) magenta (d) blue
  18. 18.🌈 Hex digits go 0 to 9, then A to which letter? (a) Z (b) J (c) G (d) F
  19. 19.🌈 Which colour is rgb(0, 255, 255)? (a) magenta (b) white (c) red (d) cyan
  20. 20.🌈 In #000c00 the green part is the hex number 0c. What is it as a normal number?
  21. 21.🌈 Which colour of light is strongest in rgb(97, 199, 51)? (a) red (b) blue (c) green
  22. 22.🌈 In #400000 the red part is the hex number 40. What is it as a normal number?
  23. 23.🌈 Which colour of light is strongest in rgb(251, 134, 45)? (a) green (b) red (c) blue
  24. 24.🌈 In #c10000 the red part is the hex number c1. What is it as a normal number?
  25. 25.🌈 Which colour is #ff0000? (a) yellow (b) black (c) magenta (d) red
  26. 26.🌈 In #006000 the green part is the hex number 60. What is it as a normal number?
  27. 27.🌈 Which colour of light is strongest in rgb(160, 122, 5)? (a) green (b) blue (c) red
  28. 28.🌈 In #000029 the blue part is the hex number 29. What is it as a normal number?
  29. 29.🌈 Which colour of light is strongest in rgb(164, 18, 33)? (a) green (b) red (c) blue
  30. 30.🌈 Which hex code is black? (a) #0000ff (b) #000000 (c) #00ffff (d) #ffff00
  31. 31.🌈 Which hex code is magenta? (a) #ff00ff (b) #000000 (c) #0000ff (d) #00ff00
  32. 32.🌈 Which colour of light is strongest in rgb(123, 209, 9)? (a) red (b) green (c) blue
  33. 33.🌈 Which colour is rgb(0, 255, 0)? (a) bright green (b) blue (c) red (d) cyan
  34. 34.🌈 Which colour is #00ff00? (a) blue (b) magenta (c) bright green (d) red
  35. 35.🌈 Which colour of light is strongest in rgb(158, 84, 110)? (a) red (b) blue (c) green
  36. 36.🌈 Which colour is rgb(0, 0, 0)? (a) magenta (b) bright green (c) red (d) black
  37. 37.🌈 Which colour of light is strongest in rgb(202, 130, 40)? (a) green (b) blue (c) red
  38. 38.🌈 Which colour of light is strongest in rgb(108, 93, 218)? (a) green (b) blue (c) red
  39. 39.🌈 Which colour of light is strongest in rgb(244, 116, 88)? (a) red (b) green (c) blue
  40. 40.🌈 In #cc0000 the red part is the hex number cc. What is it as a normal number?

Answer key

  1. green
  2. white
  3. red
  4. #00ffff
  5. blue
  6. cyan
  7. 255
  8. blue
  9. magenta
  10. blue
  11. blue
  12. 69
  13. 3
  14. blue
  15. yellow
  16. blue
  17. white
  18. F
  19. cyan
  20. 12
  21. green
  22. 64
  23. red
  24. 193
  25. red
  26. 96
  27. red
  28. 41
  29. red
  30. #000000
  31. #ff00ff
  32. green
  33. bright green
  34. bright green
  35. red
  36. black
  37. red
  38. blue
  39. red
  40. 204

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