Get detailed and reliable answers to your questions on IDNLearn.com. Ask any question and get a thorough, accurate answer from our community of experienced professionals.

Ask what kind of pet the user has. If they enter cat, print "Too bad...", if they enter dog, print "Lucky you!" (You can change the messages if you like). Once this works, add other pets. (Iguana, Pig, Rabbit...)

Sagot :

Answer:

Explanation:

a = input("what kind of pet the user has")

if a == 'cat':

  print("Too bad")

elif a == 'dog':

   print("Lucky you!")

We are delighted to have you as part of our community. Keep asking, answering, and sharing your insights. Together, we can create a valuable knowledge resource. Thank you for choosing IDNLearn.com. We’re dedicated to providing clear answers, so visit us again for more solutions.