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 A112983 #15 Jan 12 2023 01:38:19 %S A112983 0,0,1,0,4,2,4,0,7,8,4,8,4,8,1,0,4,2,4,12,16,8,4,8,14,8,25,4,4,8,4,0, %T A112983 16,8,1,20,4,8,16,32,4,2,4,32,34,8,4,32,11,48,16,32,4,2,31,8,16,8,4, %U A112983 32,4,8,16,0,64,62,4,32,16,18,4,56,4,8,61,32,36,50,4 %N A112983 a(n) = 2^(n+1) mod n. %H A112983 T. D. Noe, <a href="/A112983/b112983.txt">Table of n, a(n) for n = 1..10000</a> %F A112983 a(n) = A106262(2*n-1, n-2). - _G. C. Greubel_, Jan 11 2023 %e A112983 a(3) = 2^4 mod 3 = 16 mod 3 = 1. %t A112983 Table[PowerMod[2, n + 1, n], {n, 100}] (* _T. D. Noe_, Aug 13 2012 *) %o A112983 (Python) %o A112983 print([2**(n+1) % n for n in range(1,77)]) %o A112983 # _Alex Ratushnyak_, Aug 12 2012 %o A112983 (Magma) [Modexp(2,n+1,n): n in [1..120]]; // _G. C. Greubel_, Jan 11 2023 %o A112983 (SageMath) [power_mod(2,n+1,n) for n in range(1,120)] # _G. C. Greubel_, Jan 11 2023 %Y A112983 Cf. A106262, A212844. %K A112983 easy,nonn %O A112983 1,5 %A A112983 _Paul Barry_, Oct 08 2005 %E A112983 Name, data and offset corrected by _Alex Ratushnyak_, Aug 12 2012