1,3

Seiichi Manyama, Table of n, a(n) for n = 1..10000

a(n) = A001923(n) mod n.

a[n_] := Mod[Sum[PowerMod[k, k, n], {k, 1, n}], n]; Array[a, 100] (* Amiram Eldar, May 04 2021 *)

(PARI) a(n) = sum(k=1, n, k^k)%n;

Cf. A001923, A128981, A182398, A188775, A188776.

Sequence in context: A213407 A285310 A262946 * A216440 A094720 A334495

Adjacent sequences: A343929 A343930 A343931 * A343933 A343934 A343935

nonn,easy

Seiichi Manyama, May 04 2021

approved