OFFSET
1,5
LINKS
Jianing Song, Table of n, a(n) for n = 1..10000
EXAMPLE
There are 13 primes <= 100 that are congruent to 2 modulo 3, namely 2, 5, 11, 17, 23, 29, 41, 47, 53, 59, 71, 83, 89, so a(100) = 13.
MATHEMATICA
Accumulate[Table[If[PrimeQ[n]&&Mod[n, 3]==2, 1, 0], {n, 90}]] (* Harvey P. Dale, May 12 2022 *)
PROG
(PARI) a(n) = sum(i=1, n, isprime(i) && (i%3==2))
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Jianing Song, Apr 28 2021
STATUS
approved