0

I'm just started out in python and have no experience in programming whatsoever. Any advice would be much appreciated.

I am playing around with Python and wanted to make a simple if then statement. This is what I have so far:

def HealthDrop():
    pickup = input("You picked up a Health Drop. How much health would you like to obtain?")
    if pickup == 100:
        print("You picked up 100 Health!!!")    
    else:
        print("You can only pick up 100 Health") 
             
HealthDrop() 

This is what I want to happen: if 100 is inputted in the terminal, then print "You picked up 100 Health". If any other number is inputted in the terminal, then print "You can only pick up 100 Health"

Currently with this code, no matter what number I input into the terminal, it always prints "You can only pick up 100 Health"

0 Answers0