A364789 Initial digit of (n^n)^n (A002489(n)).
1, 1, 1, 1, 4, 2, 1, 2, 6, 1, 1, 1, 2, 1, 4, 4, 1, 3, 5, 4, 2, 1, 5, 2, 1, 5, 3, 2, 3, 7, 2, 1, 1, 4, 2, 3, 9, 7, 1, 1, 1, 1, 2, 1, 5, 5, 2, 4, 3, 1, 2, 2, 1, 3, 4, 3, 2, 6, 1, 2, 2, 1, 8, 3, 1, 3, 8, 1, 3, 5, 9, 1, 2, 4, 8, 1, 3, 1, 3, 1, 5, 3, 3, 3, 5, 1, 3
Offset: 0
Examples
a(4) = 4, since (4^4)^4 = 4^(4^2) = 4294967296.
Links
- Paolo Xausa, Table of n, a(n) for n = 0..1000
- Pointless Large numbers stuff by Cookiefonster, 2.03 The Weak Hyper-Operators.
- Wikipedia, Benford's law.
Programs
-
Mathematica
A364789[n_] := If[n == 0, 1, First[IntegerDigits[(n^n)^n]]]; Array[A364789, 100, 0] (* Paolo Xausa, Jan 31 2024 *)
-
Python
def A364789(n): return int(str((n**n)**n)[0]) # Chai Wah Wu, Aug 10 2023
Comments