calculation of decimal by rst76(thx2notogawa)

m@main=do x<-getLine;putStrLn$reverse%divMod(sum[read$y++g z|(y,_:z)<-span(>'.')`map`words x])(10^99);m
r%(x,y)=s x++'.':r(s$read$g$r$s y)
g=take 99.(++cycle"0")
s=show

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

download

return to the top page