Respuesta :
Answer:
# Write a program to get as input the value of Red, Green and Blue. The value of each can be in between 0 and 255. And if the value of Red, or Green or Blue is below 0 then it should print out of range.#
Explanation:
import time
# Enter the value of RGB#
redvalue = int(input("Enter value of RED: "))
greenvalue = int(input("Enter the value of GREEN: "))
bluevalue = int(input("Enter the value of BLUE: "))
# We now need to check the value of RGB#
if redvalue <= 255 and greenvalue <= 255 and bluevalue <= 255:
print("All the entries are correct.")
# Its more than maximum #
if redvalue > 255:
print("Red is too High.")
if greenvalue > 255:
print("Green is too High.")
if bluevalue > 255:
print("Blue is too High.")
# Its quite low #
if redvalue < 0:
print("Red is not correct.")
if greenvalue < 0:
print("Green is not correct.")
if bluevalue < 0:
print("Blue is not correct.")
Problem: Test if a date is a payday based on the day of the month (15th or the 30th).
Answer: date = int(input("Enter today's day numerically:"))
if date == 15 :
print("It's payday!")
elif date == 30 :
print("It's payday!")
else:
print("Sorry, not a payday.");
Explanation:
If it helped plz sub 2 me on YT at kustomkicks04