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.
%I A341889 #28 Jun 05 2021 17:11:39 %S A341889 2,0,3,2,3,4,2,6,3,5,4,10,2,12,5,2,3,16,2,18,3,4,10,22,3,24,9,8,6,28, %T A341889 2,30,7,17,5,6,2,36,9,5,3,40,6,42,3,4,22,46,2,20,4,16,7,52,2,14,3,5, %U A341889 28,58,2,60,9,8,3,9,2,66,11,20,4,70,3,72,20,14,3,8,5,78,4,32,40,82,2,24,29,11,3,88,2,6,7,23 %N A341889 a(n) is the smallest positive integer k > 1 such that n + k divides n^n + k, or 0 if no such k exists. %C A341889 k > 1 is needed in the definition as n+1 divides n^n+1 for all odd n. - _Chai Wah Wu_, Jun 04 2021 %H A341889 Seiichi Manyama, <a href="/A341889/b341889.txt">Table of n, a(n) for n = 1..10000</a> %t A341889 a[n_] := Module[{k = 2}, While[! Divisible[n^n + k, n + k], k++]; k]; Array[a, 100, 3] (* _Amiram Eldar_, Jun 04 2021 *) %o A341889 (PARI) a(n) = if(n==2, 0, my(k=2); while((n^n+k)%(n+k)!=0, k++); k); %Y A341889 Cf. A242789, A242801, A242899, A301941, A341760, A341844, A341890, A341902. %K A341889 nonn %O A341889 1,1 %A A341889 _Seiichi Manyama_, Jun 04 2021