Jul-28-2021, 08:24 AM
Setting
already_fed
to False
and animal
to 'Warthog', "Water" is printed, I'm not sure how you ended with result as 'Already fed!'.already_fed = False animal = 'Warthog' if already_fed: print('Already fed!') else: if animal == 'Lion': print('Meat') elif animal == 'Zebra': print('Grass') else: print('Water')
Output:Water