def count_tickets(): c_child=0 c_adult=0 c_senior=0 total=0 age=int(input("enter age ")) while(age>0): if(age>=2 and age<=12): price=10.69 c_child+=1 elif(age>=13 and age<60): price=13.69 c_adult+=1 elif(age>=60): price=12.69 c_senior+=1 else: price=0 #child less than 2 years old total+=price age=int(input("enter age ")) return c_child, c_adult, c_senior, total def main(): print(count_tickets()) main()