fork(4) download
  1. (defun sum_digits (x)
  2. (if (= x 0)
  3. 0
  4. (+ (mod x 10) (sum_digits (truncate (/ x 10))))))
  5.  
  6. (print (sum_digits (expt 2 1000)))
Success #stdin #stdout 0.03s 10944KB
stdin
Standard input is empty
stdout
1366