-
Notifications
You must be signed in to change notification settings - Fork 0
/
days_in_month.py
29 lines (29 loc) · 924 Bytes
/
days_in_month.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
month = int(input("Enter month:"))
year = int(input("Enter year:"))
if(month == 1):
print(f"year:jannuary in {year} is 31 days",)
if(month == 2):
if(year % 4 == 0):
print(f"year:february in {year} is 29 days",)
if(year % 4 != 0):
print(f"year:february in {year} is 28 days",)
if(month == 3):
print(f"year:march in {year} is 31 days",)
if(month == 4):
print(f"year:april in {year} is 30 days",)
if(month == 5):
print(f"year:may in {year} is 31 days",)
if(month == 6):
print(f"year:june in {year} is 30 days",)
if(month == 7):
print(f"year:july in {year} is 31 days",)
if(month == 8):
print(f"year:august in {year} is 31 days",)
if(month == 9):
print(f"year:september in {year} is 30 days",)
if(month == 10):
print(f"year:october in {year} is 31 days",)
if(month == 11):
print(f"year:november in {year} is 30 days",)
if(month == 12):
print(f"year:december in {year} is 31 days",)