← Colours: hex and rgb lesson New set →

CSS Worksheet: Hex and RGB Colours

HTML and CSS lesson 15: Colours: hex and rgb · Set 191 · 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(226, 21, 15)? (a) blue (b) red (c) green
  2. 2.🌈 Which colour is #0000ff? (a) blue (b) black (c) bright green (d) white
  3. 3.🌈 Which colour is #ff00ff? (a) cyan (b) magenta (c) blue (d) yellow
  4. 4.🌈 Which colour is rgb(255, 255, 0)? (a) bright green (b) yellow (c) magenta (d) red
  5. 5.🌈 In #0000fc the blue part is the hex number fc. What is it as a normal number?
  6. 6.🌈 Which colour of light is strongest in rgb(85, 186, 41)? (a) green (b) red (c) blue
  7. 7.🌈 Which colour of light is strongest in rgb(231, 26, 0)? (a) red (b) green (c) blue
  8. 8.🌈 In #rrggbb, which colour do the first two digits give? (a) black (b) blue (c) red (d) green
  9. 9.🌈 Which colour is #ff0000? (a) magenta (b) red (c) cyan (d) blue
  10. 10.🌈 Which colour is rgb(255, 0, 0)? (a) magenta (b) red (c) bright green (d) black
  11. 11.🌈 In #rrggbb, which colour do the last two digits give? (a) green (b) red (c) blue (d) white
  12. 12.🌈 Which hex code is cyan? (a) #0000ff (b) #ff0000 (c) #00ffff (d) #ff00ff
  13. 13.🌈 In #004100 the green part is the hex number 41. What is it as a normal number?
  14. 14.🌈 Hex digits go 0 to 9, then A to which letter? (a) G (b) F (c) J (d) Z
  15. 15.🌈 Which colour is rgb(255, 0, 255)? (a) red (b) black (c) magenta (d) white
  16. 16.🌈 Which colour is rgb(0, 0, 0)? (a) black (b) cyan (c) blue (d) bright green
  17. 17.🌈 Which colour of light is strongest in rgb(60, 218, 127)? (a) blue (b) red (c) green
  18. 18.🌈 Which colour of light is strongest in rgb(177, 58, 25)? (a) green (b) blue (c) red
  19. 19.🌈 Which colour of light is strongest in rgb(59, 239, 61)? (a) blue (b) green (c) red
  20. 20.🌈 In #00b500 the green part is the hex number b5. What is it as a normal number?
  21. 21.🌈 In #00da00 the green part is the hex number da. What is it as a normal number?
  22. 22.🌈 Which colour of light is strongest in rgb(130, 194, 128)? (a) green (b) red (c) blue
  23. 23.🌈 How many pairs of hex digits are in a colour like #ff8800? (a) 6 (b) 3 (c) 4 (d) 2
  24. 24.🌈 In #008a00 the green part is the hex number 8a. What is it as a normal number?
  25. 25.🌈 Which colour is #ffff00? (a) red (b) black (c) blue (d) yellow
  26. 26.🌈 Which hex code is magenta? (a) #ffff00 (b) #00ffff (c) #ff00ff (d) #0000ff
  27. 27.🌈 In #fb0000 the red part is the hex number fb. What is it as a normal number?
  28. 28.🌈 What is the biggest number one colour can have in rgb()? (a) 100 (b) 1000 (c) 255 (d) 99
  29. 29.🌈 In #00bd00 the green part is the hex number bd. What is it as a normal number?
  30. 30.🌈 In #00d500 the green part is the hex number d5. What is it as a normal number?
  31. 31.🌈 Which colour of light is strongest in rgb(113, 32, 251)? (a) green (b) red (c) blue
  32. 32.🌈 Which colour is #000000? (a) white (b) black (c) yellow (d) bright green
  33. 33.🌈 Which hex code is white? (a) #000000 (b) #ffff00 (c) #ffffff (d) #0000ff
  34. 34.🌈 Which colour of light is strongest in rgb(68, 58, 242)? (a) green (b) red (c) blue
  35. 35.🌈 Which hex code is red? (a) #ff0000 (b) #ffffff (c) #00ff00 (d) #0000ff
  36. 36.🌈 Which colour is #ffffff? (a) white (b) bright green (c) magenta (d) red
  37. 37.🌈 Which colour is rgb(0, 255, 0)? (a) cyan (b) magenta (c) black (d) bright green
  38. 38.🌈 Which colour is rgb(255, 255, 255)? (a) blue (b) red (c) yellow (d) white
  39. 39.🌈 Which colour of light is strongest in rgb(122, 72, 153)? (a) blue (b) green (c) red
  40. 40.🌈 Which colour of light is strongest in rgb(195, 6, 107)? (a) green (b) red (c) blue

Answer key

  1. red
  2. blue
  3. magenta
  4. yellow
  5. 252
  6. green
  7. red
  8. red
  9. red
  10. red
  11. blue
  12. #00ffff
  13. 65
  14. F
  15. magenta
  16. black
  17. green
  18. red
  19. green
  20. 181
  21. 218
  22. green
  23. 3
  24. 138
  25. yellow
  26. #ff00ff
  27. 251
  28. 255
  29. 189
  30. 213
  31. blue
  32. black
  33. #ffffff
  34. blue
  35. #ff0000
  36. white
  37. bright green
  38. white
  39. blue
  40. red

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