Check out example codes for "rgb(100,100,100,0.5) validation c++". It will help you in understanding the concepts better.

Code Example 1

#[a-zA-Z0-9]{6}|rgb\((?:\s*\d+\s*,){2}\s*[\d]+\)|rgba\((\s*\d+\s*,){3}[\d\.]+\)|hsl\(\s*\d+\s*(\s*\,\s*\d+\%){2}\)|hsla\(\s*\d+(\s*,\s*\d+\s*\%){2}\s*\,\s*[\d\.]+\)

Learn ReactJs, React Native from akashmittal.com