Check out example codes for "red color rgb". It will help you in understanding the concepts better.

Code Example 1

rgb(255,255,0)  /* yellow*/  Hex  #FFFF00

Code Example 2

rgb(255,0,0)  /*red*/  Hex  #FF0000

Learn ReactJs, React Native from akashmittal.com