happy number by notogawa

main=mapM print[n|n<-[1..2000],2>iterate(\n->sum[read[a]^2|a<-show n])n!!9]

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

download

return to the top page