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!)
A226217 Primes whose first digit is a square. 2
11, 13, 17, 19, 41, 43, 47, 97, 101, 103, 107, 109, 113, 127, 131, 137, 139, 149, 151, 157, 163, 167, 173, 179, 181, 191, 193, 197, 199, 401, 409, 419, 421, 431, 433, 439, 443, 449, 457, 461, 463, 467, 479, 487, 491, 499, 907, 911, 919, 929, 937, 941, 947, 953 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
LINKS
EXAMPLE
97 is a prime whose first digit is 9, which is 3^2, so 97 is a term.
MAPLE
KD := proc() local a, b, d, e; a:= ithprime(n); b:=length(a); d:=a/(10^(b-1)); e:=floor(d); if evalf(sqrt(e))=floor(evalf(sqrt(e))) then RETURN (a):fi; end:seq(KD(), n=1..200);
MATHEMATICA
Select[Prime[Range[200]], MemberQ[{1, 4, 9}, First[IntegerDigits[#]]]&] (* Harvey P. Dale, Sep 02 2023 *)
PROG
(Python)
from sympy import primerange
from itertools import count, islice
def agen(): yield from (p for e in count(1) for k in [1, 4, 9] for p in primerange(k*10**e, (k+1)*10**e))
print(list(islice(agen(), 54))) # Michael S. Branicky, Jun 25 2022
CROSSREFS
Cf. A223458 (similar sequence for primes: first digit a composite number).
Sequence in context: A249376 A068155 A271367 * A275058 A157175 A132244
KEYWORD
nonn,base
AUTHOR
K. D. Bajpai, Aug 24 2013
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 April 24 00:30 EDT 2024. Contains 371917 sequences. (Running on oeis4.)