I am trying to make it so that if two or more variables are False, then the statement ends; but the way I'm doing it, the code is taking up way too much space.
if g == False and h == False:
print("Use a different formula.")
return
elif g == False and i == False:
print("Use a different formula.")
return
elif g == False and c == False:
print("Use a different formula.")
return
elif h == False and i == False:
print("Use a different formula.")
return
elif h == False and c == False:
print("Use a different formula.")
return
elif i == False and c == False:
print("Use a different formula.")
return
elif g == False and h == False and i == False:
print("Use a different formula.")
return
elif g == False and h == False and c == False:
print("Use a different formula.")
return
elif h == False and i == False and c == False:
print("Use a different formula.")
return
elif c == False and i == False and g == False:
print("Use a different formula.")
return
elif g == False and h == False and i == False and c == False:
print("Use a different formula.")
return
This is what I have and it technically should work, but there has to be a way to shorten this. Please help.