while True:
try:
year,month,day=map(int,input().strip().split(' '))
def isrunnian(year):
if (year%4==0 and year%100!=0) or year%400==0:
return True
else:
return False
time=[31,29,31,30,31,30,31,31,30,31,30,31]
re=0
if isrunnian(year):
#print(time[:month])
re+=sum(time[:month-1])+day
else:
if month>2:
re+=sum(time[:month-1])+day-1
else:
re+=sum(time[:month-1])+day
print(re)
except:
break
import datetime
while True:
try:
a,b,c=map(int,input().split())
dd=datetime.datetime(a,b,c)
print(dd.strftime("%j").lstrip("0"))
except:
break
import datetime
while True:
try:
print(datetime.datetime(*map(int,input().split())).strftime("%j").lstrip("0"))
except:
break
我就想问,还有哪种语言比这个更简单。。