The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
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!)
A090537 Least n-digit prime using digit 3 once and rest all 1, or 0 if no such prime exists. 4
3, 13, 113, 0, 11113, 113111, 0, 11111131, 111111113, 0, 11111111113, 111113111111, 0, 31111111111111, 0, 0, 11111111113111111, 111111111111111131, 0, 11111111111111111131, 131111111111111111111, 0, 11111111111111111311111 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
LINKS
FORMULA
a(3n+1) = 0.
PROG
(Python)
from sympy import isprime
def agen():
digits = 0
while True:
for i in range(digits+1):
t = int("1"*(digits-i) + "3" + "1"*i)
if isprime(t): yield t; break
else: yield 0
digits += 1
g = agen()
print([next(g) for i in range(23)]) # Michael S. Branicky, Mar 13 2021
CROSSREFS
Without zeros, subsequence of A107689.
Sequence in context: A223911 A006860 A181083 * A063269 A105431 A360187
KEYWORD
base,nonn
AUTHOR
Amarnath Murthy, Dec 08 2003
EXTENSIONS
More terms from David Wasserman, Jan 03 2006
STATUS
approved

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 May 13 23:15 EDT 2024. Contains 372524 sequences. (Running on oeis4.)