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 A112660 #17 Sep 08 2022 08:45:23 %S A112660 1,2,24,34,10,168,84,37,183,521,588,258,655,558,281,1801,1592,3415, %T A112660 803,4898,802,5766,1659,6229,6789,7271,5870,106,3269,10734,9016,15588, %U A112660 7671,9312,14005,12985,23706,17603,3506,18337,8591,13031,30368,6754,28958,23481,36502,40139 %N A112660 a(n) = (p-1)! mod p^2 where p = n-th prime. %C A112660 Related to the Wilson primes A007540, which are primes p such that (p-1)! = -1 mod p^2. %H A112660 G. C. Greubel, <a href="/A112660/b112660.txt">Table of n, a(n) for n = 1..1000</a> %H A112660 Claire Levaillant, <a href="https://arxiv.org/abs/1912.06652">Wilson's theorem modulo p^2 derived from Faulhaber polynomials</a>, arXiv:1912.06652 [math.CO], 2019. %F A112660 a(n) = A177771(n) mod A001248(n). - _Michel Marcus_, Dec 17 2019 %p A112660 seq(`mod`(factorial(ithprime(n)-1), ithprime(n)^2), n = 1..50); # _G. C. Greubel_, Dec 17 2019 %t A112660 Table[Mod[(Prime[n]-1)!, Prime[n]^2], {n, 50}] (* _G. C. Greubel_, Dec 17 2019 *) %o A112660 (PARI) a(n) = my(p=prime(n)); (p-1)! % p^2; \\ _Michel Marcus_, Dec 17 2019 %o A112660 (Magma) [Factorial(NthPrime(n)-1) mod NthPrime(n)^2 : n in [1..50]]; // _G. C. Greubel_, Dec 17 2019 %o A112660 (Sage) [mod(factorial(nth_prime(n)-1), nth_prime(n)^2) for n in (1..50)] # _G. C. Greubel_, Dec 17 2019 %Y A112660 Cf. A001248, A007540, A177771. %K A112660 nonn %O A112660 1,2 %A A112660 _Roger Hui_, Dec 28 2005 %E A112660 Offset 1 and more terms from _Michel Marcus_, Dec 17 2019