Box Coloring by Icewing

f n y x|x<'#'=n#x|y<'#'=succ n#n|1>0=n#y
(#)n x z=putChar x>>return(n,z++[x])
g(n,(y:z))=do x<-getChar;f n(max(z!!49)y)x z>>=g
main=g('1',[1..51]>>" ")

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

download

return to the top page