cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A365689 Final decimal digit of n^((n+1)^(n+2)) = A030198(n).

This page as a plain text file.
%I A365689 #42 Apr 18 2025 14:54:54
%S A365689 0,1,2,1,4,5,6,1,8,1,0,1,2,1,4,5,6,1,8,1,0,1,2,1,4,5,6,1,8,1,0,1,2,1,
%T A365689 4,5,6,1,8,1,0,1,2,1,4,5,6,1,8,1,0,1,2,1,4,5,6,1,8,1,0,1,2,1,4,5,6,1,
%U A365689 8,1,0,1,2,1,4,5,6,1,8,1,0,1,2,1,4,5,6
%N A365689 Final decimal digit of n^((n+1)^(n+2)) = A030198(n).
%C A365689 Period 10, repeat: [0, 1, 2, 1, 4, 5, 6, 1, 8, 1].
%H A365689 Paolo Xausa, <a href="/A365689/b365689.txt">Table of n, a(n) for n = 0..1000</a>
%H A365689 <a href="/index/Rec#order_10">Index entries for linear recurrences with constant coefficients</a>, signature (0,0,0,0,0,0,0,0,0,1).
%F A365689 a(n) = n^((n+1)^(n+2)) mod 10.
%F A365689 a(n) = A103562(n) for n >= 4 (as 3^(2^1) == 9 (mod 10) instead of 1).
%F A365689 G.f.: x*(x^8+8*x^7+x^6+6*x^5+5*x^4+4*x^3+x^2+2*x+1)/(1-x^10). - _Alois P. Heinz_, Apr 18 2025
%e A365689 For n = 2, a(2) = 2417851639229258349412352 mod 10 = 2.
%t A365689 PadRight[{},100,{0,1,2,1,4,5,6,1,8,1}] (* _Paolo Xausa_, Oct 16 2023 *)
%o A365689 (PARI) a(n) = lift(Mod(n, 10)^((n+1)^(n+2))); \\ _Michel Marcus_, Sep 16 2023
%o A365689 (Python)
%o A365689 def A365689(n): return pow(n,(n+1)**(n+2),10) # _Chai Wah Wu_, Sep 22 2023
%Y A365689 Cf. A030198, A103562, A120962, A365689 (initial digit).
%K A365689 nonn,base,easy
%O A365689 0,3
%A A365689 _Marco RipĂ _, Sep 16 2023