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.
%I A000787 M4480 N1897 #44 Jan 13 2023 11:04:03 %S A000787 0,1,8,11,69,88,96,101,111,181,609,619,689,808,818,888,906,916,986, %T A000787 1001,1111,1691,1881,1961,6009,6119,6699,6889,6969,8008,8118,8698, %U A000787 8888,8968,9006,9116,9696,9886,9966,10001,10101,10801,11011,11111,11811,16091,16191 %N A000787 Strobogrammatic numbers: the same upside down. %C A000787 Strobogrammatic numbers are a kind of ambigrams that retain the same meaning when viewed upside down. - _Daniel Mondot_, Sep 27 2016 %C A000787 "Upside down" here means rotated by 180 degrees (i.e., central symmetry), NOT "vertically flipped" (symmetry w.r.t. horizontal line, which are in A045574). - _M. F. Hasler_, May 04 2012 %D A000787 N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence). %D A000787 N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence). %H A000787 Michael S. Branicky, <a href="/A000787/b000787.txt">Table of n, a(n) for n = 1..10000</a> (terms 1..1000 from T. D. Noe) %H A000787 J. M. Howell, <a href="http://www.jstor.org/stable/2688504">Strobogrammatic years</a>, Math. Mag., 34 (1961), p. 182 and 184. %H A000787 N. J. A. Sloane, <a href="https://arxiv.org/abs/2301.03149">"A Handbook of Integer Sequences" Fifty Years Later</a>, arXiv:2301.03149 [math.NT], 2023, p. 5. %t A000787 fQ[n_] := Block[{s = {0, 1, 6, 8, 9}, id = IntegerDigits[n]}, If[ Union[ Join[s, id]] == s && (id /. {6 -> 9, 9 -> 6}) == Reverse[id], True, False]]; Select[ Range[0, 16190], fQ[ # ] &] (* _Robert G. Wilson v_, Oct 11 2005 *) %o A000787 (Python) %o A000787 from itertools import count, islice, product %o A000787 def ud(s): return s[::-1].translate({ord('6'):ord('9'), ord('9'):ord('6')}) %o A000787 def agen(): %o A000787 yield from [0, 1, 8] %o A000787 for d in count(2): %o A000787 for start in "1689": %o A000787 for rest in product("01689", repeat=d//2-1): %o A000787 left = start + "".join(rest) %o A000787 right = ud(left) %o A000787 for mid in [[""], ["0", "1", "8"]][d%2]: %o A000787 yield int(left + mid + right) %o A000787 print(list(islice(agen(), 47))) # _Michael S. Branicky_, Mar 29 2022 %Y A000787 Cf. A007597 (Primes in this sequence), A057770, A111065, A169731 (another version). %Y A000787 Subsequence of A045574. - _M. F. Hasler_, May 04 2012 %K A000787 base,nonn,easy %O A000787 1,3 %A A000787 _N. J. A. Sloane_ %E A000787 More terms from _Robert G. Wilson v_, Oct 11 2005