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 A134629 #46 Feb 16 2025 08:33:07 %S A134629 1,0,3,11,15,13,17,24,23,73,101,104,103,111,115,113,117,124,123,173, %T A134629 323,373,1104,1103,1111,1115,1113,1117,1124,1123,1173,1323,1373,3323, %U A134629 3373,11373,13323,13373,17373,23323,23373,73373,101373,103323,103373,111373,113323,113373,117373,123323,123373 %N A134629 Least nonnegative integer which requires n letters to spell in English, excluding spaces and hyphens. A right inverse of A005589. %C A134629 Variant of A080777. - _R. J. Mathar_, Dec 13 2008 %C A134629 This is one of many possible right inverses of A005589, i.e., A005589 o A134629 = id (of course on the domain of this sequence, [3 .. oo)). It does not satisfy A134629 o A005589 = id. - _M. F. Hasler_, Feb 25 2018 %H A134629 Michael S. Branicky, <a href="/A134629/b134629.txt">Table of n, a(n) for n = 3..608</a> (terms < 10^54) %H A134629 Hans Havermann, <a href="/A001477/a001477.txt">Table giving n and American English name for n, for 0 <= n <= 100999, without spaces or hyphens</a> %H A134629 Landon Curt Noll, <a href="http://www.isthe.com/chongo/tech/math/number/number.html">The English Name of a Number</a>. %H A134629 Eric Weisstein's World of Mathematics, <a href="https://mathworld.wolfram.com/Number.html">Number</a>. %e A134629 a(3) = 1: "one", a(4) = 0: "zero", a(5) = 3: "three", a(6) = 11: "eleven", a(7) = 15: "fifteen", etc. %t A134629 (* first load Hans Havermann's text file a001477.txt and then *) %t A134629 f[n_] := Length@ Characters@ ToString@ lst[[n]]; g[n_] := Block[{k = 1}, While[ f[k] != n, k++]; k]; Array[g, 41, 3] - 1 (* _Robert G. Wilson v_, May 26 2013 *) %t A134629 f[n_] := Length@ StringPartition[ StringReplace[ IntegerName[n, "Words"], ", " | " " | "\[Hyphen]" -> ""], 1] (* after Giovanni Resta in A005589 *); t[_] := 0; k = 1; While[k < 174000, a = f@k; If[t[a] == 0, t[a] = k]; k++]; t[4] = 0 (* only {0, 4, 5 & 9} have just four letters *); t@# & /@ Range[3, 54] (* _Robert G. Wilson v_, May 25 2018 *) %o A134629 (PARI) A134629(n)=for(k=1,oo,A005589(k)==n&&return(k)) \\ _M. F. Hasler_, Feb 25 2018 %o A134629 (Python) %o A134629 from num2words import num2words as n2w %o A134629 from itertools import count, islice %o A134629 def f(n): return sum(1 for c in n2w(n).replace(" and", "") if c.isalpha()) %o A134629 def agen(): # generator of terms %o A134629 adict, n = dict(), 3 %o A134629 for k in count(0): %o A134629 v = f(k) %o A134629 if v not in adict: adict[v] = k %o A134629 while n in adict: yield adict[n]; n += 1 %o A134629 print(list(islice(agen(), 40))) # _Michael S. Branicky_, Feb 19 2023 %Y A134629 Cf. A005589, A052363, A080777. %K A134629 nonn,word %O A134629 3,3 %A A134629 _Robert G. Wilson v_, Nov 04 2007 %E A134629 More terms and reworded name from _M. F. Hasler_, Feb 25 2018