← Colours: hex and rgb lesson New set →

CSS Worksheet: Hex and RGB Colours

HTML and CSS lesson 15: Colours: hex and rgb · Set 85 · 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.🌈 In #rrggbb, which colour do the last two digits give? (a) red (b) blue (c) green (d) white
  2. 2.🌈 In #rrggbb, which colour do the first two digits give? (a) green (b) red (c) black (d) blue
  3. 3.🌈 Which colour is #00ffff? (a) white (b) red (c) yellow (d) cyan
  4. 4.🌈 In #002400 the green part is the hex number 24. What is it as a normal number?
  5. 5.🌈 Hex digits go 0 to 9, then A to which letter? (a) F (b) J (c) Z (d) G
  6. 6.🌈 Which colour is #00ff00? (a) white (b) bright green (c) yellow (d) blue
  7. 7.🌈 How many pairs of hex digits are in a colour like #ff8800? (a) 6 (b) 3 (c) 2 (d) 4
  8. 8.🌈 Which colour of light is strongest in rgb(27, 83, 198)? (a) red (b) blue (c) green
  9. 9.🌈 Which colour is #000000? (a) bright green (b) blue (c) black (d) red
  10. 10.🌈 Which colour is rgb(255, 0, 0)? (a) red (b) blue (c) bright green (d) black
  11. 11.🌈 Which hex code is yellow? (a) #ffffff (b) #00ff00 (c) #00ffff (d) #ffff00
  12. 12.🌈 Which hex code is white? (a) #00ff00 (b) #ff00ff (c) #0000ff (d) #ffffff
  13. 13.🌈 Which colour is #ff00ff? (a) black (b) white (c) blue (d) magenta
  14. 14.🌈 Which colour is #0000ff? (a) yellow (b) blue (c) red (d) cyan
  15. 15.🌈 In #580000 the red part is the hex number 58. What is it as a normal number?
  16. 16.🌈 Which colour is rgb(0, 0, 255)? (a) yellow (b) blue (c) red (d) bright green
  17. 17.🌈 In #4f0000 the red part is the hex number 4f. What is it as a normal number?
  18. 18.🌈 Which colour is rgb(255, 255, 0)? (a) black (b) yellow (c) blue (d) cyan
  19. 19.🌈 Which colour of light is strongest in rgb(78, 202, 24)? (a) red (b) blue (c) green
  20. 20.🌈 Which hex code is blue? (a) #ff0000 (b) #00ff00 (c) #0000ff (d) #ffff00
  21. 21.🌈 Which colour of light is strongest in rgb(66, 59, 155)? (a) blue (b) green (c) red
  22. 22.🌈 In #8d0000 the red part is the hex number 8d. What is it as a normal number?
  23. 23.🌈 In #920000 the red part is the hex number 92. What is it as a normal number?
  24. 24.🌈 Which colour of light is strongest in rgb(20, 249, 89)? (a) red (b) green (c) blue
  25. 25.🌈 Which colour of light is strongest in rgb(248, 106, 19)? (a) green (b) blue (c) red
  26. 26.🌈 In #000001 the blue part is the hex number 01. What is it as a normal number?
  27. 27.🌈 Which colour of light is strongest in rgb(121, 40, 161)? (a) red (b) blue (c) green
  28. 28.🌈 What is the biggest number one colour can have in rgb()? (a) 100 (b) 1000 (c) 255 (d) 99
  29. 29.🌈 Which colour of light is strongest in rgb(191, 119, 16)? (a) green (b) red (c) blue
  30. 30.🌈 Which colour of light is strongest in rgb(166, 117, 27)? (a) blue (b) green (c) red
  31. 31.🌈 In #810000 the red part is the hex number 81. What is it as a normal number?
  32. 32.🌈 Which colour is #ffff00? (a) bright green (b) blue (c) white (d) yellow
  33. 33.🌈 Which colour of light is strongest in rgb(108, 225, 111)? (a) blue (b) green (c) red
  34. 34.🌈 Which hex code is black? (a) #00ff00 (b) #ff00ff (c) #000000 (d) #ff0000
  35. 35.🌈 In #c60000 the red part is the hex number c6. What is it as a normal number?
  36. 36.🌈 Which hex code is bright green? (a) #00ff00 (b) #0000ff (c) #000000 (d) #00ffff
  37. 37.🌈 In #007300 the green part is the hex number 73. What is it as a normal number?
  38. 38.🌈 Which colour of light is strongest in rgb(175, 67, 90)? (a) red (b) green (c) blue
  39. 39.🌈 Which hex code is cyan? (a) #ffff00 (b) #00ff00 (c) #00ffff (d) #000000
  40. 40.🌈 Which colour of light is strongest in rgb(160, 127, 46)? (a) red (b) blue (c) green

Answer key

  1. blue
  2. red
  3. cyan
  4. 36
  5. F
  6. bright green
  7. 3
  8. blue
  9. black
  10. red
  11. #ffff00
  12. #ffffff
  13. magenta
  14. blue
  15. 88
  16. blue
  17. 79
  18. yellow
  19. green
  20. #0000ff
  21. blue
  22. 141
  23. 146
  24. green
  25. red
  26. 1
  27. blue
  28. 255
  29. red
  30. red
  31. 129
  32. yellow
  33. green
  34. #000000
  35. 198
  36. #00ff00
  37. 115
  38. red
  39. #00ffff
  40. red

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