A073862 Difference between the largest and the smallest n-digit prime.
5, 86, 896, 8964, 89984, 899980, 8999988, 89999970, 899999930, 8999999960, 89999999958, 899999999986, 8999999999932, 89999999999936, 899999999999958, 8999999999999900, 89999999999999936, 899999999999999986, 8999999999999999958, 89999999999999999938
Offset: 1
Examples
a(3) = 997 - 101 = 896. a(1) = 5 because 7-2 = 5.
Links
- Alois P. Heinz, Table of n, a(n) for n = 1..1000
Programs
-
Maple
seq(prevprime(10^n)-nextprime(10^(n-1)), n=1..21); # Emeric Deutsch, Mar 28 2005
-
Mathematica
Table[NextPrime[10^(n+1),-1]-NextPrime[10^n],{n,0,18}] (* Harvey P. Dale, May 04 2016 *)
Extensions
More terms from Emeric Deutsch, Mar 28 2005