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.

A215009 Numbers which are "easy" to key on a computer numpad.

This page as a plain text file.
%I A215009 #23 Sep 01 2022 03:45:33
%S A215009 0,1,2,3,4,5,6,7,8,9,10,12,14,20,21,23,25,32,36,41,45,47,52,54,56,58,
%T A215009 63,65,69,74,78,85,87,89,96,98,101,120,121,123,125,141,145,147,202,
%U A215009 210,212,214,232,236,252,254,256,258,320,321,323,325,363,365,369,410
%N A215009 Numbers which are "easy" to key on a computer numpad.
%C A215009 On a computer numpad, a number is "easy" to key in if each adjacent pair of digits in the number are adjacent - either horizontally or vertically.
%C A215009 Here are two ways to type these numbers. Example for 25:
%C A215009 1. Press the numpad "2" key. Then let go and press "5".
%C A215009 2. Press the "2" and slide your finger on the numeric keypad up to the "5".
%C A215009 Method 2 shows that the sequence contains only numbers in which every pair of adjacent digits are distinct.
%C A215009 Pressing a numeric key followed by "0" and pressing a numeric key is equivalent to selecting "101" or "202".
%H A215009 Arkadiusz Wesolowski, <a href="/A215009/b215009.txt">Table of n, a(n) for n = 1..10000</a>
%H A215009 Wikipedia, <a href="http://en.wikipedia.org/wiki/Numeric_keypad">Numeric keypad</a>
%H A215009 <a href="/index/Ar#10-automatic">Index entries for 10-automatic sequences</a>.
%e A215009 25 is a term because the 2 and 5 keys are adjacent.
%t A215009 lst = {}; Do[If[StringCount[ToString[n], {"00", "03", "04", "05", "06", "07", "08", "09", "11", "13", "15", "16", "17", "18", "19", "22", "24", "26", "27", "28", "29", "30", "31", "33", "34", "35", "37", "38", "39", "40", "42", "43", "44", "46", "48", "49", "50", "51", "53", "55", "57", "59", "60", "61", "62", "64", "66", "67", "68", "70", "71", "72", "73", "75", "76", "77", "79", "80", "81", "82", "83", "84", "86", "88", "90", "91", "92", "93", "94", "95", "97", "99", "102", "201"}] == 0, AppendTo[lst, n]], {n, 0, 410}]; lst
%o A215009 (Python)
%o A215009 from itertools import count, islice
%o A215009 m = {'0':'12', '1':'024', '2':'0135', '3':'26', '4':'157', '5':'2468', '6':'359', '7':'48', '8':'579', '9':'68'}
%o A215009 def c(r): return (r=='0' or r[0]!='0') and not ("102" in r or "201" in r)
%o A215009 def agen():
%o A215009     reach = list("0123456789")
%o A215009     for d in count(1):
%o A215009         yield from (int(r) for r in reach if c(r))
%o A215009         reach = [r + s for r in reach for s in m[r[-1]]]
%o A215009 print(list(islice(agen(), 62))) # _Michael S. Branicky_, Jul 05 2022
%Y A215009 Cf. A082390. Subsequence of A043096.
%K A215009 base,dumb,easy,nonn
%O A215009 1,3
%A A215009 _Arkadiusz Wesolowski_, Jul 31 2012