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.

A384131 Smallest positive number divisible by n that has n letters in US English, or 0 if none exists.

This page as a plain text file.
%I A384131 #29 May 28 2025 21:29:49
%S A384131 6,4,40,12,70,56,36,100,33,300,1000000001,406,150,112,170,162,418,
%T A384131 11020,336,528,828,4800,3300,1404,1620,1512,1218,1770,1147,1344,1353,
%U A384131 2788,3325,3888,12728,13376,13338,103360,22878,23478,27778,101728,103725,111734,111578
%N A384131 Smallest positive number divisible by n that has n letters in US English, or 0 if none exists.
%C A384131 The GCHQ reference uses British English (including "and"). The disagreements are at a(14)-a(16), which the book lists as 70000000, 15000, 14000. Furthermore, the book lists a(13) as impossible.
%D A384131 GCHQ, The GCHQ Puzzle Book, Penguin, 2016 (see p. 47).
%H A384131 Michael S. Branicky, <a href="/A384131/b384131.txt">Table of n, a(n) for n = 3..100</a> (terms 3..69 from Jason Bard)
%F A384131 a(n) >= A134629(n). - _Michael S. Branicky_, May 21 2025
%t A384131 mmax = 10^10; Do[m = n; While[StringLength[StringDelete[IntegerName[m, "Words"], {" ", "-", "\[Hyphen]", ","}]] != n, m += n; If[m > mmax, m = 0; Break[]]]; Print[m], {n, 3, 43}]
%o A384131 (Python)
%o A384131 from num2words import num2words
%o A384131 from itertools import count, islice
%o A384131 def b(n): return sum(1 for c in num2words(n).replace(" and", "") if c.isalpha())
%o A384131 def a(n): return next(k for k in count(n, n) if b(k) == n)
%o A384131 print([a(n) for n in range(3, 13)]) # _Michael S. Branicky_, May 20 2025
%Y A384131 Cf. A005589, A134629.
%K A384131 nonn,word
%O A384131 3,1
%A A384131 _Jason Bard_, May 20 2025