login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A049525
I is the first, second, eighth, ... letter in this sentence not counting spaces or commas.
5
1, 2, 8, 19, 25, 41, 51, 56, 61, 66, 71, 76, 81, 86, 91, 103, 115, 120, 126, 131, 137, 142, 148, 164, 178, 201, 222, 238, 243, 259, 307, 323, 351, 367, 405, 410, 432, 446, 451, 494, 510, 515, 532, 555, 588, 615, 631, 636, 652, 664, 680, 691, 700, 712, 723, 734
OFFSET
1,2
EXAMPLE
The sentence begins:
1234567890 1234567890 1234567890 1234567890 1234567890
Iisthefirs tsecondeig hthninetee nthtwentyf ifthfortyf
irstfiftyf irstfiftys ixthsixtyf irstsixtys ixthsevent
yfirstseve ntysixthei ghtyfirste ightysixth ninetyfirs
tonehundre dthirdoneh undredfift eenthonehu ndredtwent
iethonehun dredtwenty sixthonehu ndredthirt yfirstoneh
undredthir tyseventho nehundredf ortysecond onehundred ...
MATHEMATICA
seed="iisthe"; s[1]=1; s[2]=2; name[n_]:=
StringReplace[IntegerName[n, {"English", "Ordinal"}], {"-"->"", " "->""}];
s[n_]:=seed=StringJoin[seed<>name[StringPosition[seed, "i"][[n-2, 1]]]];
l=s/@Range[56]; Table[StringPosition[Last[l], "i"][[k, 1]], {k, 1, Length[l]}]
(* Ivan N. Ianakiev, Apr 02 2022 *)
PROG
(Python)
from num2words import num2words
from itertools import islice
def n2w(n):
os = num2words(n, ordinal=True).replace(" and", "")
return os.replace(" ", "").replace("-", "").replace(", ", "")
def agen(): # generator of terms
s, idx = "iisthe", 0
while True:
idx_rel = 1 + s.index("i")
idx += idx_rel
yield idx
s = s[idx_rel:] + n2w(idx)
print(list(islice(agen(), 56))) # Michael S. Branicky, Apr 02 2022
CROSSREFS
Sequence in context: A072675 A033711 A093012 * A286263 A236327 A109071
KEYWORD
nonn,word,easy,nice
AUTHOR
EXTENSIONS
More terms from Robert G. Wilson v, Jul 18 2000
Corrected and extended by Larry Reeves (larryr(AT)acm.org), Nov 02 2000
STATUS
approved