← Colours: hex and rgb lesson New set →

CSS Worksheet: Hex and RGB Colours

HTML and CSS lesson 15: Colours: hex and rgb · Set 53 · 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 rgb(0, 255, 0)? (a) yellow (b) cyan (c) white (d) bright green
  2. 2.🌈 Which colour is #ff00ff? (a) white (b) yellow (c) magenta (d) red
  3. 3.🌈 Hex digits go 0 to 9, then A to which letter? (a) G (b) Z (c) J (d) F
  4. 4.🌈 In #00004d the blue part is the hex number 4d. What is it as a normal number?
  5. 5.🌈 In #0000f9 the blue part is the hex number f9. What is it as a normal number?
  6. 6.🌈 In #rrggbb, which colour do the first two digits give? (a) green (b) red (c) blue (d) black
  7. 7.🌈 In #rrggbb, which colour do the last two digits give? (a) white (b) red (c) blue (d) green
  8. 8.🌈 Which colour of light is strongest in rgb(40, 104, 151)? (a) blue (b) green (c) red
  9. 9.🌈 Which hex code is bright green? (a) #0000ff (b) #000000 (c) #00ff00 (d) #ff00ff
  10. 10.🌈 Which colour of light is strongest in rgb(76, 202, 106)? (a) green (b) blue (c) red
  11. 11.🌈 Which hex code is black? (a) #ffffff (b) #000000 (c) #ff0000 (d) #00ff00
  12. 12.🌈 Which colour of light is strongest in rgb(50, 83, 223)? (a) green (b) red (c) blue
  13. 13.🌈 What is the biggest number one colour can have in rgb()? (a) 100 (b) 1000 (c) 99 (d) 255
  14. 14.🌈 Which hex code is yellow? (a) #00ffff (b) #000000 (c) #ffff00 (d) #00ff00
  15. 15.🌈 Which hex code is magenta? (a) #0000ff (b) #ffffff (c) #ff00ff (d) #ffff00
  16. 16.🌈 Which colour is rgb(0, 0, 0)? (a) magenta (b) cyan (c) black (d) yellow
  17. 17.🌈 Which colour of light is strongest in rgb(207, 27, 66)? (a) red (b) blue (c) green
  18. 18.🌈 Which colour of light is strongest in rgb(190, 0, 76)? (a) green (b) blue (c) red
  19. 19.🌈 Which colour of light is strongest in rgb(53, 81, 246)? (a) green (b) red (c) blue
  20. 20.🌈 In #420000 the red part is the hex number 42. What is it as a normal number?
  21. 21.🌈 How many pairs of hex digits are in a colour like #ff8800? (a) 2 (b) 6 (c) 3 (d) 4
  22. 22.🌈 Which colour of light is strongest in rgb(118, 98, 190)? (a) green (b) red (c) blue
  23. 23.🌈 Which colour is rgb(255, 255, 255)? (a) yellow (b) white (c) bright green (d) red
  24. 24.🌈 Which colour of light is strongest in rgb(183, 111, 95)? (a) blue (b) green (c) red
  25. 25.🌈 Which colour is rgb(0, 0, 255)? (a) white (b) blue (c) yellow (d) bright green
  26. 26.🌈 Which hex code is blue? (a) #000000 (b) #0000ff (c) #00ff00 (d) #ffff00
  27. 27.🌈 Which colour is #00ffff? (a) bright green (b) white (c) cyan (d) black
  28. 28.🌈 In #00000e the blue part is the hex number 0e. What is it as a normal number?
  29. 29.🌈 Which colour is rgb(255, 0, 255)? (a) red (b) blue (c) magenta (d) bright green
  30. 30.🌈 In #110000 the red part is the hex number 11. What is it as a normal number?
  31. 31.🌈 In #000065 the blue part is the hex number 65. What is it as a normal number?
  32. 32.🌈 Which colour is #00ff00? (a) bright green (b) blue (c) white (d) yellow
  33. 33.🌈 Which colour is #ff0000? (a) cyan (b) red (c) blue (d) bright green
  34. 34.🌈 Which colour is #0000ff? (a) blue (b) yellow (c) cyan (d) magenta
  35. 35.🌈 Which hex code is red? (a) #ffff00 (b) #ff0000 (c) #0000ff (d) #000000
  36. 36.🌈 Which colour of light is strongest in rgb(162, 72, 44)? (a) blue (b) red (c) green
  37. 37.🌈 In #b50000 the red part is the hex number b5. What is it as a normal number?
  38. 38.🌈 In #780000 the red part is the hex number 78. What is it as a normal number?
  39. 39.🌈 Which colour of light is strongest in rgb(162, 60, 128)? (a) green (b) blue (c) red
  40. 40.🌈 Which colour of light is strongest in rgb(195, 18, 41)? (a) green (b) red (c) blue

Answer key

  1. bright green
  2. magenta
  3. F
  4. 77
  5. 249
  6. red
  7. blue
  8. blue
  9. #00ff00
  10. green
  11. #000000
  12. blue
  13. 255
  14. #ffff00
  15. #ff00ff
  16. black
  17. red
  18. red
  19. blue
  20. 66
  21. 3
  22. blue
  23. white
  24. red
  25. blue
  26. #0000ff
  27. cyan
  28. 14
  29. magenta
  30. 17
  31. 101
  32. bright green
  33. red
  34. blue
  35. #ff0000
  36. red
  37. 181
  38. 120
  39. red
  40. red

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