%I #23 Jan 18 2022 10:14:42
%S 1,7,11,31,397,409,1657,2131,7607
%N Numbers d such that, for some k, the upper and lower primes closest to k! are k! + d and k! - d.
%C This sequence lists d = nextprime(k!) - k! = prevprime(k!) - k! for k in A053709.
%e For k = 10, k! = 3628800, d = 11, and the closest primes to 10! are q = 10! - 11 = 3628789 and p = 10! + 11 = 3628811. The differences d are listed here.
%t Reap[Do[If[SameQ @@ #, Sow@ First[#]] &@ Abs[# - NextPrime[#, {-1, 1}]] &[i!], {i, 200}]][[-1, -1]] (* _Michael De Vlieger_, Jan 14 2022 *)
%Y Cf. A033932, A033933, A006990, A037151, A006562, A053709, A053710.
%K nonn,hard,more
%O 1,2
%A _Labos Elemer_, Feb 10 2000
%E a(5)-a(8) from _Donovan Johnson_, Oct 12 2008
%E a(9) from _Hans Havermann_, Aug 15 2014