cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A263620 Number of nonzero palindromic squares with at most 2n digits.

Original entry on oeis.org

3, 6, 14, 19, 30, 36, 55, 69, 94, 112, 161, 192, 263, 309, 414, 485, 639, 740, 949, 1081, 1373, 1555
Offset: 1

Views

Author

N. J. A. Sloane, Oct 23 2015

Keywords

Crossrefs

Programs

  • Mathematica
    Table[Length[Select[Range[1, Floor[Sqrt[10^(2 n)]]], PalindromeQ[#^2] &]], {n, 6}] (* Robert Price, Apr 26 2019 *)
  • Python
    def ispal(n): s = str(n); return s == s[::-1]
    def a(n):
      c, k, kk = 0, 1, 1
      while kk < 10**(2*n): c, k, kk = c + (ispal(kk)), k+1, kk + 2*k + 1
      return c
    print([a(n) for n in range(1, 8)]) # Michael S. Branicky, Mar 06 2021

Formula

Equals A263619(2n)-1.

Extensions

a(7)-a(10) from Chai Wah Wu, Oct 25 2015
More terms using A263618 from Chai Wah Wu, Jun 14 2024