m@main=getLine>>=print.(0%).('+':)>>m a%(o:s)|[(x,t)]<-reads s=last$(a+x)%t:[a*x%t|o<'+'] a%_=a
Note that non-ascii characters in the above source code will be escaped (such as \x9f).
download
return to the top page