← Colours: hex and rgb lesson New set →

CSS Worksheet: Hex and RGB Colours

HTML and CSS lesson 15: Colours: hex and rgb · Set 153 · 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 #830000 the red part is the hex number 83. What is it as a normal number?
  2. 2.🌈 How many pairs of hex digits are in a colour like #ff8800? (a) 2 (b) 4 (c) 6 (d) 3
  3. 3.🌈 In #100000 the red part is the hex number 10. What is it as a normal number?
  4. 4.🌈 Which colour of light is strongest in rgb(14, 130, 250)? (a) blue (b) green (c) red
  5. 5.🌈 Which hex code is red? (a) #00ff00 (b) #ffff00 (c) #ff0000 (d) #00ffff
  6. 6.🌈 Which colour of light is strongest in rgb(66, 19, 254)? (a) green (b) blue (c) red
  7. 7.🌈 Which colour of light is strongest in rgb(163, 54, 83)? (a) blue (b) green (c) red
  8. 8.🌈 Which colour is rgb(0, 0, 255)? (a) magenta (b) black (c) red (d) blue
  9. 9.🌈 What is the biggest number one colour can have in rgb()? (a) 99 (b) 1000 (c) 100 (d) 255
  10. 10.🌈 Which colour is #0000ff? (a) yellow (b) white (c) bright green (d) blue
  11. 11.🌈 In #rrggbb, which colour do the first two digits give? (a) blue (b) black (c) green (d) red
  12. 12.🌈 Which colour of light is strongest in rgb(112, 38, 168)? (a) green (b) blue (c) red
  13. 13.🌈 Which colour is rgb(0, 0, 0)? (a) black (b) cyan (c) yellow (d) red
  14. 14.🌈 Which colour is rgb(255, 0, 0)? (a) magenta (b) black (c) red (d) bright green
  15. 15.🌈 Which colour is rgb(255, 255, 255)? (a) black (b) white (c) red (d) magenta
  16. 16.🌈 Which colour of light is strongest in rgb(178, 23, 49)? (a) green (b) red (c) blue
  17. 17.🌈 Hex digits go 0 to 9, then A to which letter? (a) J (b) F (c) G (d) Z
  18. 18.🌈 Which colour of light is strongest in rgb(213, 95, 18)? (a) red (b) green (c) blue
  19. 19.🌈 Which colour is rgb(0, 255, 255)? (a) cyan (b) white (c) yellow (d) blue
  20. 20.🌈 Which colour of light is strongest in rgb(228, 102, 90)? (a) blue (b) green (c) red
  21. 21.🌈 Which colour is rgb(0, 255, 0)? (a) bright green (b) cyan (c) black (d) blue
  22. 22.🌈 Which colour of light is strongest in rgb(93, 36, 194)? (a) green (b) blue (c) red
  23. 23.🌈 Which colour is #ffff00? (a) yellow (b) white (c) blue (d) black
  24. 24.🌈 Which colour of light is strongest in rgb(31, 100, 180)? (a) green (b) red (c) blue
  25. 25.🌈 Which colour of light is strongest in rgb(133, 48, 236)? (a) red (b) blue (c) green
  26. 26.🌈 In #rrggbb, which colour do the last two digits give? (a) white (b) red (c) blue (d) green
  27. 27.🌈 In #760000 the red part is the hex number 76. What is it as a normal number?
  28. 28.🌈 Which hex code is bright green? (a) #00ff00 (b) #ffff00 (c) #00ffff (d) #ff0000
  29. 29.🌈 Which colour is rgb(255, 255, 0)? (a) yellow (b) red (c) bright green (d) black
  30. 30.🌈 In #00007b the blue part is the hex number 7b. What is it as a normal number?
  31. 31.🌈 Which colour of light is strongest in rgb(14, 161, 60)? (a) blue (b) red (c) green
  32. 32.🌈 Which hex code is black? (a) #0000ff (b) #000000 (c) #ffffff (d) #00ffff
  33. 33.🌈 Which hex code is cyan? (a) #ff00ff (b) #00ffff (c) #ffffff (d) #ffff00
  34. 34.🌈 In #620000 the red part is the hex number 62. What is it as a normal number?
  35. 35.🌈 Which colour of light is strongest in rgb(79, 208, 84)? (a) green (b) blue (c) red
  36. 36.🌈 Which colour of light is strongest in rgb(187, 69, 38)? (a) red (b) blue (c) green
  37. 37.🌈 In #00cd00 the green part is the hex number cd. What is it as a normal number?
  38. 38.🌈 Which colour is #ff0000? (a) red (b) bright green (c) yellow (d) cyan
  39. 39.🌈 Which colour of light is strongest in rgb(194, 14, 116)? (a) blue (b) green (c) red
  40. 40.🌈 Which hex code is white? (a) #0000ff (b) #ffff00 (c) #ffffff (d) #00ff00

Answer key

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

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