Run ID:93670

提交时间:2024-10-18 21:18:22

a=[31,28,31,30,31,30,31,31,30,31,30,31] #平年每个月的天数 x,y,z=map(int,input().split()) res=0 if (x%4==0 and x%100!=0) or x%400==0: #如果是润年的话 if y>=3: #如果是大于2月了 for i in range(y-1): res+=a[i] res=res+z+1 else: for i in range(y-1): res+=a[i] res+=z else: #是平年 for i in range(y-1): res+=a[i] res+=z print(res)