BWT by Defenestrator

import List
main@f=do s@(h:t)<-getLine;let m=sort[v++s|v<-tails t]in putStrLn$show(sum[1|x<-m,x<s])++' ':map(!!length t)m;f

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

download

return to the top page