login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A154579 Primes p = prime(k) such that all the digits of the concatenation of p and k are distinct. 2

%I #17 May 18 2023 13:52:56

%S 2,3,5,7,13,19,23,29,37,47,53,59,67,71,73,89,97,103,107,149,167,173,

%T 197,241,269,271,281,283,347,349,359,401,439,461,463,467,487,503,521,

%U 569,593,659,683,829,839,853,863,953,1487,1489,1607,1609,1637,2087,2089

%N Primes p = prime(k) such that all the digits of the concatenation of p and k are distinct.

%H Robert Israel, <a href="/A154579/b154579.txt">Table of n, a(n) for n = 1..101</a> (contains all the members of the sequence).

%p f:= proc(k) local p, Lk, Lp, m;

%p p:= ithprime(k);

%p Lk:= convert(k,base,10);

%p Lp:= convert(p,base,10);

%p if nops(Lk)+nops(Lp) = nops(convert(Lk,set) union convert(Lp,set)) then p fi

%p end proc:

%p map(f, [$1..10^5]); # _Robert Israel_, Oct 24 2019

%t Do[a=FromDigits[Join[Flatten[IntegerDigits[{Prime[n],n}]]]];If[Max[DigitCount[a]] == 1,Print[Prime[n]]],{n,1,10^3}] (* _Metin Sariyar_, Oct 25 2019 *)

%t Select[Prime[Range[400]],Max[DigitCount[# 10^IntegerLength[PrimePi[#]]+PrimePi[#]]]<2&] (* _Harvey P. Dale_, May 18 2023 *)

%Y Cf. A000040.

%K nonn,fini,full,base

%O 1,1

%A _Juri-Stepan Gerasimov_, Jan 12 2009

%E Removed 43 (which shares digits with 14) and 479 (which shares digits with 92) - _R. J. Mathar_, Feb 27 2009

%E Edited by _N. J. A. Sloane_, Aug 04 2009

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 19 19:02 EDT 2024. Contains 371798 sequences. (Running on oeis4.)