y = int(input())
d = int(input())
days = [0, 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31]
if (y % 4 == 0 and y % 100 != 0) or y % 400 == 0:
days[2] = 29
count = 0
for index in range(13):
m = count
count += days[index]
if count >= d:
print(index) # 月份
print(d - m)
break
CCF Python题解(100分)201509-2 日期计算
最新推荐文章于 2021-01-14 07:56:47 发布