samedi 2 décembre 2017

How to make it so that the word "male" is not counted as in "female"?

gender = input("What is your gender? ")
if 'male' in gender:
    print("You are a boy!")
if 'female' in gender:
    print("You are a girl!")

May I ask how do I make it so that "male" won't be counted part of "female"?

It would always print "You are a boy!"

Aucun commentaire:

Enregistrer un commentaire