← Colours: hex and rgb lesson New set →

CSS Worksheet: Hex and RGB Colours

HTML and CSS lesson 15: Colours: hex and rgb · Set 364 · 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.🌈 What is the biggest number one colour can have in rgb()? (a) 1000 (b) 99 (c) 100 (d) 255
  2. 2.🌈 Which hex code is cyan? (a) #00ffff (b) #ffff00 (c) #00ff00 (d) #0000ff
  3. 3.🌈 In #rrggbb, which colour do the last two digits give? (a) red (b) blue (c) green (d) white
  4. 4.🌈 Which colour is #ffff00? (a) yellow (b) magenta (c) black (d) blue
  5. 5.🌈 Which colour is #ff0000? (a) red (b) bright green (c) yellow (d) blue
  6. 6.🌈 In #007600 the green part is the hex number 76. What is it as a normal number?
  7. 7.🌈 Which colour is #00ff00? (a) white (b) black (c) bright green (d) yellow
  8. 8.🌈 In #rrggbb, which colour do the first two digits give? (a) blue (b) black (c) green (d) red
  9. 9.🌈 Which colour is rgb(0, 0, 255)? (a) cyan (b) bright green (c) black (d) blue
  10. 10.🌈 Which hex code is white? (a) #00ffff (b) #ffffff (c) #0000ff (d) #000000
  11. 11.🌈 Which hex code is red? (a) #ff0000 (b) #0000ff (c) #ff00ff (d) #00ff00
  12. 12.🌈 How many pairs of hex digits are in a colour like #ff8800? (a) 2 (b) 6 (c) 3 (d) 4
  13. 13.🌈 Which colour of light is strongest in rgb(221, 47, 128)? (a) red (b) blue (c) green
  14. 14.🌈 Which colour of light is strongest in rgb(17, 126, 177)? (a) red (b) blue (c) green
  15. 15.🌈 Which colour of light is strongest in rgb(44, 242, 66)? (a) red (b) green (c) blue
  16. 16.🌈 Which colour is rgb(0, 255, 0)? (a) red (b) magenta (c) white (d) bright green
  17. 17.🌈 In #00e600 the green part is the hex number e6. What is it as a normal number?
  18. 18.🌈 Which colour of light is strongest in rgb(94, 198, 40)? (a) blue (b) green (c) red
  19. 19.🌈 Hex digits go 0 to 9, then A to which letter? (a) Z (b) F (c) G (d) J
  20. 20.🌈 Which colour is rgb(0, 0, 0)? (a) yellow (b) black (c) magenta (d) cyan
  21. 21.🌈 Which hex code is bright green? (a) #00ffff (b) #00ff00 (c) #ffff00 (d) #ffffff
  22. 22.🌈 Which colour is rgb(255, 0, 0)? (a) red (b) blue (c) cyan (d) magenta
  23. 23.🌈 Which colour of light is strongest in rgb(56, 158, 138)? (a) red (b) blue (c) green
  24. 24.🌈 Which colour of light is strongest in rgb(165, 34, 42)? (a) green (b) blue (c) red
  25. 25.🌈 In #000d00 the green part is the hex number 0d. What is it as a normal number?
  26. 26.🌈 Which colour of light is strongest in rgb(181, 64, 19)? (a) blue (b) green (c) red
  27. 27.🌈 Which colour is rgb(0, 255, 255)? (a) blue (b) black (c) bright green (d) cyan
  28. 28.🌈 In #a00000 the red part is the hex number a0. What is it as a normal number?
  29. 29.🌈 Which colour of light is strongest in rgb(180, 76, 134)? (a) blue (b) green (c) red
  30. 30.🌈 Which colour of light is strongest in rgb(174, 103, 139)? (a) red (b) green (c) blue
  31. 31.🌈 In #260000 the red part is the hex number 26. What is it as a normal number?
  32. 32.🌈 In #0000f8 the blue part is the hex number f8. What is it as a normal number?
  33. 33.🌈 Which colour is rgb(255, 255, 0)? (a) red (b) cyan (c) yellow (d) white
  34. 34.🌈 In #003d00 the green part is the hex number 3d. What is it as a normal number?
  35. 35.🌈 In #000000 the green part is the hex number 00. What is it as a normal number?
  36. 36.🌈 In #6e0000 the red part is the hex number 6e. What is it as a normal number?
  37. 37.🌈 Which colour is #000000? (a) magenta (b) black (c) yellow (d) red
  38. 38.🌈 Which colour of light is strongest in rgb(73, 31, 232)? (a) red (b) green (c) blue
  39. 39.🌈 Which colour is #0000ff? (a) yellow (b) black (c) blue (d) magenta
  40. 40.🌈 In #aa0000 the red part is the hex number aa. What is it as a normal number?

Answer key

  1. 255
  2. #00ffff
  3. blue
  4. yellow
  5. red
  6. 118
  7. bright green
  8. red
  9. blue
  10. #ffffff
  11. #ff0000
  12. 3
  13. red
  14. blue
  15. green
  16. bright green
  17. 230
  18. green
  19. F
  20. black
  21. #00ff00
  22. red
  23. green
  24. red
  25. 13
  26. red
  27. cyan
  28. 160
  29. red
  30. red
  31. 38
  32. 248
  33. yellow
  34. 61
  35. 0
  36. 110
  37. black
  38. blue
  39. blue
  40. 170

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