Hi I am new to programming and I am writing a program that will ask the user to type in a colour. The program will then tell the user if that colour is a primary colour for paint, light, both or neither.
primary colours are red, blue and yellow
primary colours for light are red, blue and green.
This is my code so far:
a = input("Enter Colour: ")
if 'Yellow' in a:
print('Yellow is a primary coulour for paint.')
elif 'Green' in a:
print('Green is a primary colour for light.')
elif 'blue' in a:
print('blue is a primary colour for light and paint.')
elif 'red' in a:
print('red is a primary colour for light and paint')
else:
print(a,'is not a primary colour.')
The problem I am having with this code is when I use different cases. For example the input blue should give the same output as Blue or BLUe.
So I want the program to ignore the case.
Anything would help thanks.