CALC fixed by notogawa

m@main=do s<-getLine;putStrLn$unwords$f[x|x<-s,x<'0']id$words[last$x:[' '|x<'0']|x<-s];m
f[]g[n]=[n,"=",show$g$read n]
f(a:x)g(n:y)=n:[a]:f x([(-),(*),(+)]!!mod(fromEnum a-1)4$g$read n)y

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

download

return to the top page