OFFSET
1
LINKS
FORMULA
MATHEMATICA
a[n_] := If[IntegerExponent[n, 2] == 1 && PrimePowerQ[n/2], 1, 0]; Array[a, 100] ( * Amiram Eldar, Jun 15 2022 *)
Module[{nn=150, c}, c=Union[Flatten[Table[2 p^k, {p, Prime[Range[2, 35]]}, {k, 5}]]]; Table[If[ MemberQ[ c, k], 1, 0], {k, nn}]] (* Harvey P. Dale, Sep 18 2023 *)
PROG
(PARI) A354981(n) = (2==(n%4) && isprimepower(n/2));
CROSSREFS
KEYWORD
nonn
AUTHOR
Antti Karttunen, Jun 15 2022
STATUS
approved