OFFSET
1,2
COMMENTS
No terms are congruent to 7 mod 8: subsequence of A004777.
LINKS
Vincenzo Librandi, Table of n, a(n) for n = 1..2500
EXAMPLE
12 is in this sequence because 2^3+2^2 = 12.
51 is in this sequence because 2^1+7^2 = 51.
MATHEMATICA
nn=15; Union[Select[Flatten[Table[2^x + y^2, {x, 0, nn}, {y, 0, nn}]], # <=nn^2 &]]
PROG
(PARI) isok(n) = {k=0; while (2^k <= n, if (issquare(n - 2^k), return(1)); k++; ); return (0); } \\ Michel Marcus, Nov 24 2014
CROSSREFS
KEYWORD
nonn
AUTHOR
Vincenzo Librandi, Nov 24 2014
STATUS
approved