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!)
A062338 Primes whose sum of digits is a multiple of 4. 4
13, 17, 31, 53, 71, 79, 97, 103, 107, 211, 233, 251, 277, 349, 367, 389, 431, 439, 457, 479, 503, 521, 547, 569, 587, 619, 659, 673, 677, 691, 701, 709, 727, 839, 853, 857, 907, 929, 947, 983, 1021, 1061, 1069, 1087, 1151, 1201, 1223, 1249, 1289, 1429 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
LINKS
EXAMPLE
349 is a prime with sum of digits =16=4*4, hence belongs to the sequence.
MAPLE
filter:= x -> (convert(convert(x, base, 10), `+`) mod 4 = 0) and isprime(x);
A062338:= select(filter, [seq(2*i+1, i=0..1000)]); # Robert Israel, Apr 20 2014
PROG
(Magma) [ p: p in PrimesUpTo(10000) | &+Intseq(p) mod 4 eq 0 ]; /* Vincenzo Librandi, Apr 02 2011 */
(PARI) is(n)=isprime(n) && sumdigits(n)%4==0 \\ Charles R Greathouse IV, Mar 09 2022
CROSSREFS
Subsequence of A119449.
Sequence in context: A129338 A138535 A116671 * A143863 A158571 A176882
KEYWORD
nonn,base,easy
AUTHOR
Amarnath Murthy, Jun 21 2001
EXTENSIONS
Corrected and extended by Larry Reeves (larryr(AT)acm.org), Jul 06 2001
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 August 21 21:44 EDT 2024. Contains 375353 sequences. (Running on oeis4.)