(compile(defun f(n a p x)(if(=(mod n p)0)(f(/ n p)(*(- p x)a)p 0)(if(>(* p p)n)(*(max 1(1- n))a)(f n a(+(min 2(1- p))p)1)))))(loop(format t"~A "(f(read)1 2 1)))
Note that non-ascii characters in the above source code will be escaped (such as \x9f).
download
return to the top page