OFFSET
1,4
FORMULA
a(n) = A033873(n-1) - 1. - Michel Marcus, Jul 28 2016
EXAMPLE
For n=4, the smallest 4-digit prime is 1009, and 10^(4-1) + 1 = 1001, so a(4) = 1009 - 1001 = 8. - Michael B. Porter, Aug 01 2016
MATHEMATICA
Table[NextPrime[#] - (# + 1) &[10^(n - 1)], {n, 75}] (* Michael De Vlieger, Jul 13 2016 *)
PROG
(PARI) a(n) = nextprime(10^(n-1)) - (10^(n-1) + 1); \\ Michel Marcus, Jul 28 2016
CROSSREFS
KEYWORD
base,nonn
AUTHOR
Carauleanu Marc, Jul 13 2016
STATUS
approved