subject

Ask the user to enter a number for red, green, and blue components of an RGB value, which takes a certain amount of red, green, and blue colors and produces a new color. Test the numbers that are input by the user and check that each value is between 0 and 255 (inclusive). If a color's value is outside of this range, print which color's number is not correct (e. g., "Red number is not correct" if the red value is 300). Multiple colors may be out of range. The order of the colors should be the same as the sample runs below; red, then green, then blue. Hint: Since this lesson uses boolean operators, remember to use at least one boolean operator in each of your answers to receive full credit.

Sample Run 1
Enter the red: 150
Enter the green: 300
Enter the blue: 15
Sample Output 1
Green number is not correct.
Sample Run 2
Enter the red: 25
Enter the green: 124
Enter the blue: 105
Sample Output 2
Nothing is output if a user enters three numbers that are all within the range of 0 to 255.

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 23.06.2019 13:30
Spoons are designed to be used for: spring hammering. applying body filler. identifying high and low spots. sanding highly formed areas.
Answers: 3
question
Computers and Technology, 23.06.2019 18:00
Which finger presses the h key on the keyboard? index finger on the left hand pinky finger on the right hand index finger on the right hand thumb on the left hand
Answers: 1
question
Computers and Technology, 24.06.2019 13:00
What are some websites that you can read manga (ex: manga rock)
Answers: 1
question
Computers and Technology, 24.06.2019 16:00
How are roger williams, james oglethorpe, and william penn similar?
Answers: 3
You know the right answer?
Ask the user to enter a number for red, green, and blue components of an RGB value, which takes a ce...
Questions
question
Biology, 20.04.2020 00:12
question
Mathematics, 20.04.2020 00:13
Questions on the website: 13722362