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.

A350218 a(1) = 1. a(n) is the smallest unlisted number, the name of which does not contain the first letter of the name of a(n-1) in US English.

This page as a plain text file.
%I A350218 #8 Dec 20 2021 19:14:37
%S A350218 1,3,4,2,5,6,8,30,7,9,12,11,32,100,10,101,13,104,15,16,14,17,18,34,
%T A350218 105,19,33,106,20,107,23,109,25,111,26,400,21,401,22,404,27,405,28,
%U A350218 406,29,407,31,409,36,411,37,500,38,501,39,504,60,24,505,61,35,506,62,40,63,41,66,42,67,43
%N A350218 a(1) = 1. a(n) is the smallest unlisted number, the name of which does not contain the first letter of the name of a(n-1) in US English.
%t A350218 name[n_]:=IntegerName[n,"Words"]; a[1]=1;
%t A350218 a[n_]:=a[n]=Module[{i=1}, While[ Or[ MemberQ[Table[a[k],{k,1,n-1}],i],
%t A350218 StringContainsQ[name[i],StringTake[name[a[n-1]],1]]], i++ ]; i];
%t A350218 a/@Range[70]
%o A350218 (Python)
%o A350218 from num2words import num2words
%o A350218 def n2w(n): return num2words(n).replace(" and", "")
%o A350218 def aupton(terms):
%o A350218     alst, aset = [1], {1}
%o A350218     for n in range(2, terms+1):
%o A350218         an = 1
%o A350218         avoid = n2w(alst[-1])[0]
%o A350218         while an in aset or avoid in n2w(an): an += 1
%o A350218         alst.append(an); aset.add(an)
%o A350218     return alst
%o A350218 print(aupton(70)) # _Michael S. Branicky_, Dec 20 2021
%Y A350218 Cf. A350217, A277971, A277972.
%K A350218 nonn,word
%O A350218 1,2
%A A350218 _Ivan N. Ianakiev_, Dec 20 2021