Write a Python program to classify the given input according to different categories.
salary = 30000
category = "medium"

def classify(salary):
 if salary <= 10000:
 return "low"
 elif salary <=30000:
 return "medium"
 else:
 return "high"

result = classify(30000)
print(result)