← Colours: hex and rgb lesson New set →

CSS Worksheet: Hex and RGB Colours

HTML and CSS lesson 15: Colours: hex and rgb · Set 158 · 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(78, 118, 237)? (a) red (b) green (c) blue
  2. 2.🌈 Which colour is #0000ff? (a) black (b) blue (c) cyan (d) bright green
  3. 3.🌈 Which hex code is cyan? (a) #ffffff (b) #0000ff (c) #00ffff (d) #00ff00
  4. 4.🌈 Which colour is rgb(0, 0, 255)? (a) magenta (b) black (c) blue (d) red
  5. 5.🌈 Hex digits go 0 to 9, then A to which letter? (a) G (b) J (c) Z (d) F
  6. 6.🌈 Which hex code is red? (a) #ffffff (b) #00ff00 (c) #000000 (d) #ff0000
  7. 7.🌈 Which colour is #ffff00? (a) blue (b) cyan (c) bright green (d) yellow
  8. 8.🌈 In #rrggbb, which colour do the first two digits give? (a) red (b) blue (c) green (d) black
  9. 9.🌈 In #rrggbb, which colour do the last two digits give? (a) red (b) blue (c) white (d) green
  10. 10.🌈 How many pairs of hex digits are in a colour like #ff8800? (a) 2 (b) 4 (c) 6 (d) 3
  11. 11.🌈 In #990000 the red part is the hex number 99. What is it as a normal number?
  12. 12.🌈 Which colour is #000000? (a) cyan (b) black (c) magenta (d) red
  13. 13.🌈 Which colour of light is strongest in rgb(34, 185, 74)? (a) green (b) blue (c) red
  14. 14.🌈 Which colour is rgb(255, 255, 0)? (a) yellow (b) black (c) cyan (d) magenta
  15. 15.🌈 In #ad0000 the red part is the hex number ad. What is it as a normal number?
  16. 16.🌈 Which colour is #ffffff? (a) magenta (b) white (c) blue (d) cyan
  17. 17.🌈 Which colour of light is strongest in rgb(48, 116, 241)? (a) green (b) red (c) blue
  18. 18.🌈 Which colour of light is strongest in rgb(114, 153, 93)? (a) green (b) blue (c) red
  19. 19.🌈 Which colour of light is strongest in rgb(78, 210, 2)? (a) green (b) blue (c) red
  20. 20.🌈 Which colour is rgb(0, 255, 0)? (a) white (b) yellow (c) red (d) bright green
  21. 21.🌈 Which hex code is yellow? (a) #ff0000 (b) #ffff00 (c) #0000ff (d) #00ffff
  22. 22.🌈 Which colour of light is strongest in rgb(64, 250, 70)? (a) green (b) red (c) blue
  23. 23.🌈 Which hex code is magenta? (a) #ff00ff (b) #ff0000 (c) #0000ff (d) #000000
  24. 24.🌈 In #1c0000 the red part is the hex number 1c. What is it as a normal number?
  25. 25.🌈 What is the biggest number one colour can have in rgb()? (a) 99 (b) 1000 (c) 255 (d) 100
  26. 26.🌈 Which colour is #ff0000? (a) bright green (b) blue (c) red (d) magenta
  27. 27.🌈 Which hex code is bright green? (a) #ffffff (b) #ffff00 (c) #00ff00 (d) #000000
  28. 28.🌈 Which colour is rgb(255, 0, 0)? (a) cyan (b) yellow (c) bright green (d) red
  29. 29.🌈 Which colour of light is strongest in rgb(93, 130, 165)? (a) red (b) blue (c) green
  30. 30.🌈 Which hex code is blue? (a) #ff00ff (b) #000000 (c) #0000ff (d) #ffffff
  31. 31.🌈 In #000e00 the green part is the hex number 0e. What is it as a normal number?
  32. 32.🌈 In #b30000 the red part is the hex number b3. What is it as a normal number?
  33. 33.🌈 In #340000 the red part is the hex number 34. What is it as a normal number?
  34. 34.🌈 Which colour is #00ff00? (a) magenta (b) bright green (c) white (d) yellow
  35. 35.🌈 In #d10000 the red part is the hex number d1. What is it as a normal number?
  36. 36.🌈 Which colour is #00ffff? (a) white (b) cyan (c) red (d) black
  37. 37.🌈 In #0000f4 the blue part is the hex number f4. What is it as a normal number?
  38. 38.🌈 Which colour is rgb(0, 0, 0)? (a) white (b) red (c) black (d) yellow
  39. 39.🌈 Which colour is rgb(255, 255, 255)? (a) black (b) white (c) magenta (d) red
  40. 40.🌈 Which colour of light is strongest in rgb(249, 8, 134)? (a) blue (b) green (c) red

Answer key

  1. blue
  2. blue
  3. #00ffff
  4. blue
  5. F
  6. #ff0000
  7. yellow
  8. red
  9. blue
  10. 3
  11. 153
  12. black
  13. green
  14. yellow
  15. 173
  16. white
  17. blue
  18. green
  19. green
  20. bright green
  21. #ffff00
  22. green
  23. #ff00ff
  24. 28
  25. 255
  26. red
  27. #00ff00
  28. red
  29. blue
  30. #0000ff
  31. 14
  32. 179
  33. 52
  34. bright green
  35. 209
  36. cyan
  37. 244
  38. black
  39. white
  40. red

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