← Colours: hex and rgb lesson New set →

CSS Worksheet: Hex and RGB Colours

HTML and CSS lesson 15: Colours: hex and rgb · Set 93 · 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(240, 10, 74)? (a) blue (b) green (c) red
  2. 2.🌈 Which colour is #ff00ff? (a) bright green (b) magenta (c) blue (d) yellow
  3. 3.🌈 Which colour of light is strongest in rgb(159, 26, 93)? (a) blue (b) red (c) green
  4. 4.🌈 Which colour of light is strongest in rgb(116, 23, 249)? (a) red (b) green (c) blue
  5. 5.🌈 Which colour is #ffff00? (a) bright green (b) black (c) yellow (d) magenta
  6. 6.🌈 Which colour is #ffffff? (a) red (b) blue (c) black (d) white
  7. 7.🌈 Which colour is rgb(255, 0, 255)? (a) black (b) magenta (c) bright green (d) red
  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 rgb(0, 255, 0)? (a) red (b) blue (c) magenta (d) bright green
  10. 10.🌈 Hex digits go 0 to 9, then A to which letter? (a) J (b) F (c) Z (d) G
  11. 11.🌈 How many pairs of hex digits are in a colour like #ff8800? (a) 4 (b) 3 (c) 2 (d) 6
  12. 12.🌈 Which colour is rgb(255, 255, 0)? (a) yellow (b) white (c) black (d) red
  13. 13.🌈 In #rrggbb, which colour do the last two digits give? (a) white (b) blue (c) green (d) red
  14. 14.🌈 In #0000a1 the blue part is the hex number a1. What is it as a normal number?
  15. 15.🌈 In #420000 the red part is the hex number 42. What is it as a normal number?
  16. 16.🌈 Which hex code is bright green? (a) #00ffff (b) #0000ff (c) #ff00ff (d) #00ff00
  17. 17.🌈 Which colour is #ff0000? (a) blue (b) cyan (c) red (d) bright green
  18. 18.🌈 Which colour of light is strongest in rgb(248, 58, 133)? (a) red (b) green (c) blue
  19. 19.🌈 What is the biggest number one colour can have in rgb()? (a) 99 (b) 255 (c) 100 (d) 1000
  20. 20.🌈 Which colour is #00ff00? (a) magenta (b) white (c) blue (d) bright green
  21. 21.🌈 Which colour of light is strongest in rgb(16, 191, 137)? (a) red (b) blue (c) green
  22. 22.🌈 Which hex code is yellow? (a) #0000ff (b) #00ff00 (c) #ffff00 (d) #ff0000
  23. 23.🌈 Which hex code is cyan? (a) #ff0000 (b) #ff00ff (c) #ffffff (d) #00ffff
  24. 24.🌈 Which colour of light is strongest in rgb(173, 6, 69)? (a) red (b) blue (c) green
  25. 25.🌈 Which colour is #000000? (a) cyan (b) black (c) bright green (d) red
  26. 26.🌈 In #000014 the blue part is the hex number 14. What is it as a normal number?
  27. 27.🌈 Which colour of light is strongest in rgb(172, 42, 23)? (a) green (b) blue (c) red
  28. 28.🌈 Which colour is rgb(255, 0, 0)? (a) bright green (b) cyan (c) red (d) blue
  29. 29.🌈 In #780000 the red part is the hex number 78. What is it as a normal number?
  30. 30.🌈 Which colour of light is strongest in rgb(107, 5, 158)? (a) blue (b) red (c) green
  31. 31.🌈 In #000005 the blue part is the hex number 05. What is it as a normal number?
  32. 32.🌈 In #00f900 the green part is the hex number f9. What is it as a normal number?
  33. 33.🌈 In #c70000 the red part is the hex number c7. What is it as a normal number?
  34. 34.🌈 Which colour of light is strongest in rgb(185, 21, 5)? (a) green (b) red (c) blue
  35. 35.🌈 In #ef0000 the red part is the hex number ef. What is it as a normal number?
  36. 36.🌈 Which colour is rgb(0, 0, 255)? (a) black (b) white (c) red (d) blue
  37. 37.🌈 Which colour of light is strongest in rgb(211, 136, 53)? (a) green (b) blue (c) red
  38. 38.🌈 Which colour is rgb(255, 255, 255)? (a) white (b) blue (c) cyan (d) red
  39. 39.🌈 Which colour is #0000ff? (a) blue (b) yellow (c) cyan (d) bright green
  40. 40.🌈 In #00006f the blue part is the hex number 6f. What is it as a normal number?

Answer key

  1. red
  2. magenta
  3. red
  4. blue
  5. yellow
  6. white
  7. magenta
  8. red
  9. bright green
  10. F
  11. 3
  12. yellow
  13. blue
  14. 161
  15. 66
  16. #00ff00
  17. red
  18. red
  19. 255
  20. bright green
  21. green
  22. #ffff00
  23. #00ffff
  24. red
  25. black
  26. 20
  27. red
  28. red
  29. 120
  30. blue
  31. 5
  32. 249
  33. 199
  34. red
  35. 239
  36. blue
  37. red
  38. white
  39. blue
  40. 111

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