OFFSET
1
LINKS
MATHEMATICA
a[n_] := If[PrimePowerQ[n] || PrimeQ[n/2], 1, 0]; a[1] = 1; Array[a, 100] (* Amiram Eldar, Jun 13 2022 *)
PROG
(PARI) A354923(n) = ((1==n)|| isprimepower(n) || (!(n%2) && isprime(n/2)));
CROSSREFS
KEYWORD
nonn
AUTHOR
Antti Karttunen, Jun 13 2022
STATUS
approved