So I'm fairly new to python and for my programming class, I have to write a program about a 100 metre race and tells if you qualified or not based on the time it took you to finish. If you're a male and you took longer than 10.18 seconds to finish; then you didn't qualify. If you're a female and it took you longer than 11.29 seconds to finish; then again, you didn't qualify.
My problem is that both messages saying if you qualified or didn't qualified appear no matter what your time was. I am using Python 2.7.10. My code so far is:
gender = raw_input("Are you Male (M) or Female (F)?: ")
time = raw_input("What time did you get for the 100m race?: ")
if gender is "M" and time > 10.18:
print "Sorry, you did not qualify"
else:
print "Congratulations, you qualified!"
if gender is "F" and time > 11.29:
print "Sorry, you did not qualify"
else:
print "Congratulations, you qualified!"