OFFSET
1,1
LINKS
Robert Israel, Table of n, a(n) for n = 1..10000
MAPLE
g := proc (n) local m, k;
for m from 0 do
k := max(2, ceil(3*10^m/n));
if k*n < 4*10^m then return k*n end if
end do
end proc:
seq(g(ithprime(i)), i=1..100); # Robert Israel, Feb 12 2018
MATHEMATICA
f[n_] := Block[{k = 2, m = n}, While[ IntegerDigits[k*m][[1]] != 3, k++ ]; k*m]; Table[ f[ Prime[n]], {n, 1, 55}]
PROG
(PARI) a(n) = {my(k=2, p=prime(n)); while(digits(k*p)[1] != 3, k++); k*p; } \\ Michel Marcus, Feb 12 2018
CROSSREFS
KEYWORD
AUTHOR
Amarnath Murthy, Nov 26 2002
EXTENSIONS
Edited, corrected and extended by Robert G. Wilson v, Nov 29 2002
STATUS
approved