← Colours: hex and rgb lesson New set →

CSS Worksheet: Hex and RGB Colours

HTML and CSS lesson 15: Colours: hex and rgb · Set 292 · 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 is rgb(255, 255, 255)? (a) black (b) bright green (c) yellow (d) white
  2. 2.🌈 Which colour is #ffffff? (a) red (b) white (c) blue (d) cyan
  3. 3.🌈 Which colour is #ff00ff? (a) red (b) magenta (c) bright green (d) yellow
  4. 4.🌈 Which colour is #ff0000? (a) red (b) black (c) cyan (d) blue
  5. 5.🌈 Which hex code is cyan? (a) #00ffff (b) #00ff00 (c) #ffff00 (d) #ff00ff
  6. 6.🌈 Which colour is #00ff00? (a) white (b) black (c) bright green (d) magenta
  7. 7.🌈 Which colour of light is strongest in rgb(26, 6, 225)? (a) blue (b) green (c) red
  8. 8.🌈 In #rrggbb, which colour do the last two digits give? (a) white (b) red (c) green (d) blue
  9. 9.🌈 Which colour of light is strongest in rgb(203, 53, 69)? (a) green (b) red (c) blue
  10. 10.🌈 Which colour is rgb(0, 0, 0)? (a) red (b) bright green (c) black (d) magenta
  11. 11.🌈 In #200000 the red part is the hex number 20. What is it as a normal number?
  12. 12.🌈 Which colour is rgb(0, 0, 255)? (a) yellow (b) blue (c) bright green (d) red
  13. 13.🌈 Which hex code is black? (a) #00ffff (b) #ffff00 (c) #000000 (d) #ff0000
  14. 14.🌈 In #00b300 the green part is the hex number b3. What is it as a normal number?
  15. 15.🌈 How many pairs of hex digits are in a colour like #ff8800? (a) 4 (b) 6 (c) 3 (d) 2
  16. 16.🌈 Which colour of light is strongest in rgb(20, 225, 122)? (a) green (b) red (c) blue
  17. 17.🌈 Which colour of light is strongest in rgb(16, 167, 69)? (a) red (b) green (c) blue
  18. 18.🌈 In #rrggbb, which colour do the first two digits give? (a) red (b) blue (c) green (d) black
  19. 19.🌈 Which colour of light is strongest in rgb(206, 85, 18)? (a) blue (b) red (c) green
  20. 20.🌈 Which colour of light is strongest in rgb(208, 39, 20)? (a) green (b) red (c) blue
  21. 21.🌈 Which hex code is blue? (a) #ffffff (b) #00ff00 (c) #ffff00 (d) #0000ff
  22. 22.🌈 In #007300 the green part is the hex number 73. What is it as a normal number?
  23. 23.🌈 Which colour is rgb(255, 0, 0)? (a) yellow (b) cyan (c) blue (d) red
  24. 24.🌈 What is the biggest number one colour can have in rgb()? (a) 99 (b) 100 (c) 255 (d) 1000
  25. 25.🌈 Which hex code is bright green? (a) #ffff00 (b) #000000 (c) #ffffff (d) #00ff00
  26. 26.🌈 Which colour is #ffff00? (a) yellow (b) red (c) bright green (d) blue
  27. 27.🌈 Which colour is rgb(0, 255, 255)? (a) white (b) red (c) blue (d) cyan
  28. 28.🌈 Which colour is rgb(255, 255, 0)? (a) black (b) yellow (c) red (d) cyan
  29. 29.🌈 In #700000 the red part is the hex number 70. What is it as a normal number?
  30. 30.🌈 Which colour of light is strongest in rgb(82, 42, 240)? (a) blue (b) red (c) green
  31. 31.🌈 Hex digits go 0 to 9, then A to which letter? (a) G (b) J (c) Z (d) F
  32. 32.🌈 Which colour of light is strongest in rgb(42, 205, 53)? (a) blue (b) red (c) green
  33. 33.🌈 Which colour of light is strongest in rgb(55, 224, 81)? (a) red (b) green (c) blue
  34. 34.🌈 Which hex code is white? (a) #ffffff (b) #ffff00 (c) #000000 (d) #ff00ff
  35. 35.🌈 In #000094 the blue part is the hex number 94. What is it as a normal number?
  36. 36.🌈 Which colour is #0000ff? (a) yellow (b) black (c) blue (d) white
  37. 37.🌈 Which colour is #000000? (a) bright green (b) magenta (c) yellow (d) black
  38. 38.🌈 In #eb0000 the red part is the hex number eb. What is it as a normal number?
  39. 39.🌈 Which hex code is yellow? (a) #ff0000 (b) #ffff00 (c) #0000ff (d) #ff00ff
  40. 40.🌈 Which colour of light is strongest in rgb(192, 103, 67)? (a) blue (b) red (c) green

Answer key

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

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