← Colours: hex and rgb lesson New set →

CSS Worksheet: Hex and RGB Colours

HTML and CSS lesson 15: Colours: hex and rgb · Set 2 · 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(13, 186, 60)? (a) blue (b) red (c) green
  2. 2.🌈 Which colour is rgb(255, 255, 0)? (a) magenta (b) yellow (c) cyan (d) black
  3. 3.🌈 Which colour is rgb(255, 0, 0)? (a) cyan (b) blue (c) red (d) bright green
  4. 4.🌈 In #rrggbb, which colour do the last two digits give? (a) green (b) red (c) white (d) blue
  5. 5.🌈 Which colour of light is strongest in rgb(81, 39, 220)? (a) red (b) green (c) blue
  6. 6.🌈 Which hex code is red? (a) #ff00ff (b) #ff0000 (c) #00ffff (d) #ffffff
  7. 7.🌈 Which colour is #000000? (a) white (b) black (c) magenta (d) red
  8. 8.🌈 Which hex code is black? (a) #000000 (b) #ffff00 (c) #00ffff (d) #ffffff
  9. 9.🌈 Which colour is #ff0000? (a) blue (b) red (c) magenta (d) white
  10. 10.🌈 Which hex code is blue? (a) #00ff00 (b) #ff0000 (c) #0000ff (d) #ffff00
  11. 11.🌈 In #rrggbb, which colour do the first two digits give? (a) black (b) green (c) red (d) blue
  12. 12.🌈 Which colour of light is strongest in rgb(108, 224, 136)? (a) green (b) blue (c) red
  13. 13.🌈 Which colour of light is strongest in rgb(190, 140, 101)? (a) red (b) green (c) blue
  14. 14.🌈 Which hex code is magenta? (a) #00ff00 (b) #ffffff (c) #ffff00 (d) #ff00ff
  15. 15.🌈 How many pairs of hex digits are in a colour like #ff8800? (a) 6 (b) 2 (c) 3 (d) 4
  16. 16.🌈 Which colour is #ff00ff? (a) magenta (b) bright green (c) blue (d) white
  17. 17.🌈 In #000054 the blue part is the hex number 54. What is it as a normal number?
  18. 18.🌈 Which colour is rgb(0, 255, 0)? (a) yellow (b) black (c) cyan (d) bright green
  19. 19.🌈 In #ff0000 the red part is the hex number ff. What is it as a normal number?
  20. 20.🌈 Which colour is rgb(0, 255, 255)? (a) bright green (b) cyan (c) black (d) magenta
  21. 21.🌈 Which hex code is cyan? (a) #00ffff (b) #000000 (c) #ffffff (d) #00ff00
  22. 22.🌈 Hex digits go 0 to 9, then A to which letter? (a) J (b) F (c) Z (d) G
  23. 23.🌈 Which colour is #ffffff? (a) white (b) cyan (c) blue (d) magenta
  24. 24.🌈 Which hex code is bright green? (a) #0000ff (b) #ffffff (c) #00ff00 (d) #000000
  25. 25.🌈 In #000034 the blue part is the hex number 34. What is it as a normal number?
  26. 26.🌈 Which colour is #0000ff? (a) blue (b) magenta (c) yellow (d) white
  27. 27.🌈 Which colour is rgb(0, 0, 255)? (a) yellow (b) black (c) blue (d) bright green
  28. 28.🌈 In #3b0000 the red part is the hex number 3b. What is it as a normal number?
  29. 29.🌈 What is the biggest number one colour can have in rgb()? (a) 100 (b) 99 (c) 1000 (d) 255
  30. 30.🌈 In #000027 the blue part is the hex number 27. What is it as a normal number?
  31. 31.🌈 In #00008e the blue part is the hex number 8e. What is it as a normal number?
  32. 32.🌈 In #6a0000 the red part is the hex number 6a. What is it as a normal number?
  33. 33.🌈 Which colour of light is strongest in rgb(183, 135, 122)? (a) blue (b) red (c) green
  34. 34.🌈 Which colour of light is strongest in rgb(22, 251, 89)? (a) red (b) blue (c) green
  35. 35.🌈 Which colour of light is strongest in rgb(104, 0, 158)? (a) red (b) blue (c) green
  36. 36.🌈 In #610000 the red part is the hex number 61. What is it as a normal number?
  37. 37.🌈 Which hex code is yellow? (a) #00ffff (b) #ffff00 (c) #ff0000 (d) #00ff00
  38. 38.🌈 In #000009 the blue part is the hex number 09. What is it as a normal number?
  39. 39.🌈 Which colour is rgb(0, 0, 0)? (a) black (b) magenta (c) blue (d) cyan
  40. 40.🌈 Which colour of light is strongest in rgb(37, 52, 220)? (a) red (b) blue (c) green

Answer key

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

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