right time by nn

D=86400,v=$0{$0="0 31 59 90 120 151 181 212 243 273 304 334"
y=int((v-32001)/365/D)
l=y%4~2
v-=int((1461*y+1)/4)*D
for(m=1;m<13&&$++m+(l&&m>2)<v/D;);v-=($--m+(l&&m>2))*D
printf"%d-%02d-%02d %02d:%02d:%02d\n",y+1970,m,(v-=y>2?--y>12&&--y>13&&--y>14&&--y>14&&--y>17&&--y>21&&--y>22?22+(y>29):y:0)/D+1,v/3600%24,v/60%60,v%60}

Note that non-ascii characters in the above source code will be escaped (such as \x9f).

download

return top