题解 | 计算日期到天数转换
计算日期到天数转换
https://www.nowcoder.com/practice/769d45d455fe40b385ba32f97e7bcded
l = [31,31,30,31,30,31,31,30,31,30,31]
def isrun(x):
if x%4==0 and x%100 != 0:
return True
if x %400 == 0:
return True
a,b,c = map(int,input().split())
if isrun(a):
l.insert(1,29)
else:
l.insert(1,28)
print(sum(l[i] for i in range(b-1))+c)

