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!)
A268704 Greatest n-digit prime having at least n-1 digits equal to 3. 2

%I #17 Apr 11 2020 18:39:00

%S 7,83,733,7333,38333,733333,3733333,83333333,373333333,3334333333,

%T 38333333333,383333333333,3433333333333,53333333333333,

%U 383333333333333,3733333333333333,43333333333333333,353333333333333333,3333334333333333333,33343333333333333333

%N Greatest n-digit prime having at least n-1 digits equal to 3.

%H Michel Lagneau, Michael De Vlieger and Robert G. Wilson v, <a href="/A268704/b268704.txt">Table of n, a(n) for n = 1..1000</a>

%t f[n_] := Block[{k = 0, p = {}, r = (10^n - 1)/3, s = Range@ 10 - 4}, While[k < n, AppendTo[p, Select[r + 10^k*s, PrimeQ]]; k++]; p = Max@ Flatten@ p]; Array[f, 20]

%t Table[Max[Select[FromDigits/@Flatten[Permutations/@Table[PadRight[{n},k,3],{n,{1,2,4,5,7,8}}],1],IntegerLength[#]==k&&PrimeQ[#]&]],{k,20}] (* _Harvey P. Dale_, Apr 11 2020 *)

%Y Cf. A178001, A241100, A268702 - A268707, A241206, A266142.

%K base,nonn

%O 1,1

%A _Michel Lagneau_, _Michael De Vlieger_ and _Robert G. Wilson v_, Feb 11 2016

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 March 28 09:04 EDT 2024. Contains 371240 sequences. (Running on oeis4.)