← Colours: hex and rgb lesson New set →

CSS Worksheet: Hex and RGB Colours

HTML and CSS lesson 15: Colours: hex and rgb · Set 179 · 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.🌈 Hex digits go 0 to 9, then A to which letter? (a) J (b) G (c) Z (d) F
  2. 2.🌈 Which colour is #ffff00? (a) black (b) bright green (c) blue (d) yellow
  3. 3.🌈 Which colour is #ff00ff? (a) blue (b) yellow (c) magenta (d) black
  4. 4.🌈 Which colour of light is strongest in rgb(209, 115, 86)? (a) blue (b) green (c) red
  5. 5.🌈 Which colour is rgb(255, 255, 0)? (a) bright green (b) cyan (c) yellow (d) red
  6. 6.🌈 Which colour is #00ffff? (a) red (b) magenta (c) yellow (d) cyan
  7. 7.🌈 Which colour of light is strongest in rgb(12, 139, 224)? (a) blue (b) green (c) red
  8. 8.🌈 Which colour of light is strongest in rgb(84, 156, 6)? (a) red (b) blue (c) green
  9. 9.🌈 Which colour is rgb(255, 0, 255)? (a) bright green (b) yellow (c) white (d) magenta
  10. 10.🌈 Which hex code is red? (a) #00ffff (b) #ff0000 (c) #0000ff (d) #000000
  11. 11.🌈 Which colour of light is strongest in rgb(71, 100, 188)? (a) blue (b) red (c) green
  12. 12.🌈 Which colour is #ff0000? (a) yellow (b) bright green (c) blue (d) red
  13. 13.🌈 Which hex code is magenta? (a) #00ffff (b) #ff00ff (c) #00ff00 (d) #000000
  14. 14.🌈 How many pairs of hex digits are in a colour like #ff8800? (a) 6 (b) 3 (c) 2 (d) 4
  15. 15.🌈 Which colour is rgb(0, 0, 0)? (a) blue (b) bright green (c) cyan (d) black
  16. 16.🌈 Which colour is rgb(255, 0, 0)? (a) cyan (b) red (c) blue (d) magenta
  17. 17.🌈 Which colour is #ffffff? (a) yellow (b) white (c) black (d) bright green
  18. 18.🌈 In #005200 the green part is the hex number 52. What is it as a normal number?
  19. 19.🌈 Which colour of light is strongest in rgb(23, 181, 136)? (a) green (b) blue (c) red
  20. 20.🌈 In #002600 the green part is the hex number 26. What is it as a normal number?
  21. 21.🌈 Which colour is rgb(0, 255, 0)? (a) yellow (b) bright green (c) blue (d) white
  22. 22.🌈 In #00003f the blue part is the hex number 3f. What is it as a normal number?
  23. 23.🌈 In #rrggbb, which colour do the first two digits give? (a) blue (b) green (c) black (d) red
  24. 24.🌈 Which colour is #00ff00? (a) white (b) black (c) yellow (d) bright green
  25. 25.🌈 Which colour is rgb(255, 255, 255)? (a) magenta (b) cyan (c) blue (d) white
  26. 26.🌈 Which colour of light is strongest in rgb(180, 52, 16)? (a) green (b) blue (c) red
  27. 27.🌈 In #0000b3 the blue part is the hex number b3. What is it as a normal number?
  28. 28.🌈 What is the biggest number one colour can have in rgb()? (a) 99 (b) 100 (c) 1000 (d) 255
  29. 29.🌈 Which hex code is white? (a) #ffffff (b) #ff0000 (c) #ff00ff (d) #ffff00
  30. 30.🌈 Which colour is #0000ff? (a) black (b) white (c) blue (d) red
  31. 31.🌈 In #d90000 the red part is the hex number d9. What is it as a normal number?
  32. 32.🌈 Which colour of light is strongest in rgb(24, 151, 59)? (a) red (b) blue (c) green
  33. 33.🌈 Which colour is rgb(0, 255, 255)? (a) yellow (b) red (c) bright green (d) cyan
  34. 34.🌈 In #007600 the green part is the hex number 76. What is it as a normal number?
  35. 35.🌈 Which colour of light is strongest in rgb(26, 235, 97)? (a) blue (b) red (c) green
  36. 36.🌈 In #00000d the blue part is the hex number 0d. What is it as a normal number?
  37. 37.🌈 Which colour of light is strongest in rgb(4, 223, 62)? (a) green (b) blue (c) red
  38. 38.🌈 Which colour is #000000? (a) yellow (b) black (c) white (d) bright green
  39. 39.🌈 In #d60000 the red part is the hex number d6. What is it as a normal number?
  40. 40.🌈 Which colour of light is strongest in rgb(16, 7, 187)? (a) red (b) green (c) blue

Answer key

  1. F
  2. yellow
  3. magenta
  4. red
  5. yellow
  6. cyan
  7. blue
  8. green
  9. magenta
  10. #ff0000
  11. blue
  12. red
  13. #ff00ff
  14. 3
  15. black
  16. red
  17. white
  18. 82
  19. green
  20. 38
  21. bright green
  22. 63
  23. red
  24. bright green
  25. white
  26. red
  27. 179
  28. 255
  29. #ffffff
  30. blue
  31. 217
  32. green
  33. cyan
  34. 118
  35. green
  36. 13
  37. green
  38. black
  39. 214
  40. blue

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