Header Ads Widget

Responsive Advertisement

Write A Program To Take Two Inputs Day, Month And Then Calculate Which Day Of The Year

 Write A Program To Take Two Inputs Day, Month And Then Calculate Which Day Of The Year

 

# Write A Program To Take Two Inputs Day, Month And Then Calculate Which Day Of The Year

day = int(input("Enter the day : "))
month = int(input("Enter the month : "))
if day > 30 or month > 12:
print("Invalid day and month !!!")
else:
print("Its ", (month - 1) * 30 + day, " day of the year")

 

Post a Comment

0 Comments