Magic square by youz

(do*((n(read))(s(* n n))(i 0)(x 0(mod i n))(d(ash n -1))(a(- s d 1)(mod(- a(if(= x 0)n(-(* n 2)-1(if(=(mod(-(floor i n)x)n)d)n 0))))s)))((format(<=(incf i)s)"~[~&~:; ~]~3,' D"x(1+ a))))

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

download

return to the top page