You are viewing a single comment's thread. Return to all comments →
you dont need anything else than some nested if n else.
date,month,year = map(int,input().strip().split()) DueDate,DueMonth,DueYear = map(int,input().strip().split()) DayLate = date-DueDate monthLate = month-DueMonth yearLate = year-DueYear if yearLate==0: if monthLate==0: if DayLate<=0: print(0) else: print(DayLate*15) elif monthLate < 0 : print(0) else: print(500*monthLate) elif yearLate < 0: print(0) else: print(10000)
Seems like cookies are disabled on this browser, please enable them to open this website
Nested Logic
You are viewing a single comment's thread. Return to all comments →
you dont need anything else than some nested if n else.