I'm trying to make an age calculator for python and I have a problem with subtracting the user's input date of birth and today's date. I have tried float but it doesn't work. I tried subtracting the variables itself but that doesn't work, either.
age_str = input ("Enter your birthday on dd-mm-yy Format:")```
age = datetime.datetime.strptime(age_str, '%d-%m-%Y')```
today_str = datetime.date.today()```
today = datetime.datetime.strptime(today_str, '%d-%m-%Y')```
total = age - today```