Complete the code to set the background color to pure red using RGB.
background-color: rgb([1], 0, 0);
The red value in RGB ranges from 0 to 255. To get pure red, set red to 255 and green and blue to 0.
Complete the code to set a semi-transparent blue background using RGBA.
background-color: rgba(0, 0, [1], 0.5);
In RGBA, the blue value is the third number. 255 means full blue. The last value 0.5 sets 50% transparency.
Fix the error in this RGBA color that should be semi-transparent green.
color: rgba(0, [1], 0, 0.3);
The green value must be between 0 and 255. 255 is full green. 300 is invalid and causes error.
Fill both blanks to create a background color with half-transparent yellow using RGBA.
background-color: rgba([1], [2], 0, 0.5);
Yellow is made by mixing red and green at full intensity (255), blue is 0. Alpha 0.5 means 50% transparency.
Fill all three blanks to create a background color with 75% transparent purple using RGBA.
background-color: rgba([1], [2], [3], 0.25);
Purple is made by mixing red and blue. Here red is 64, green 0, blue 255. Alpha 0.25 means 75% transparent.