The series, 11 + 22 + 33 + ... + 1010 = 10405071317.
Find the last ten digits of the series, 11 + 22 + 33 + ... + 10001000.
;pow ;pow-mod (defn p48 [] (println (let [mod (pow 10 10)] (rem (apply + (map #(pow-mod % % mod) (range 1 1001))) mod) ) ) )
%pow %pow_mod p48()-> M=pow(10,10), io:format("~w~n",[lists:sum(lists:map(fun(X)->pow_mod(X,X,M) end, lists:seq(1,1000))) rem M]).
#power_mod def p48 p=10**10 puts (1..1000).map{|i|power_mod(i,i,p)}.sum%p end