login

Reminder: The OEIS is hiring a new managing editor, and the application deadline is January 26.

Numbers n such that n, p[n], p[n]+n, p[n]-n and p[n]*n all are 8-less.
8

%I #3 Mar 30 2012 17:26:11

%S 1,2,5,7,9,10,11,12,14,15,17,20,21,25,26,32,33,34,40,46,50,54,55,57,

%T 63,64,70,73,74,90,95,97,99,100,104,105,110,113,114,115,116,117,119,

%U 137,156,191,192,200,203,204,213,220,225,226,227,240,244,261,262,264,265

%N Numbers n such that n, p[n], p[n]+n, p[n]-n and p[n]*n all are 8-less.

%C From the first 3000 primes, only 356 are such that n, p[n], p[n]+n, p[n]-n and p[n]*n all are 8-less.

%t id[x_]:=IntegerDigits[x];pr[i_]:=Prime[i];ra=Range[3000];A104428=Select[ra, Position[Union[id[ # ], id[pr[ # ]], id[pr[ # ]+# ], id[pr[ # ]-# ], id[pr[ # ]*# ]], 8]=={}&]

%Y Cf. A104419-A104428.

%K nonn,base

%O 1,2

%A _Zak Seidov_, Mar 07 2005