login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A358406 The index of A358405 where n first appears, or 0 if n never appears. 3
1, 3, 5, 10, 16, 8, 19, 141, 14, 190, 25, 22, 416, 70, 54, 162, 32, 308, 169, 67, 93, 203, 118, 513, 196, 29, 40, 200, 861, 37, 74, 1081, 82, 216, 208, 363, 90, 46, 375, 1675, 1091, 333, 1407, 812, 166, 78, 51, 1099, 115, 193, 1243, 64, 595, 98, 58, 367, 617, 235, 325, 766, 2137, 272, 124 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,2
COMMENTS
See A358405 for further details.
LINKS
PROG
(Python)
from itertools import count, islice
def agen():
k, an, first, prev = 0, 0, {0: 1}, {0: 1}
for n in count(2):
while k in first: yield first[k]; k += 1
an1 = 0 if first[an] == n-1 else max(n-1-prev[an], first[an])
if an1 not in first: first[an1] = prev[an1] = n
prev[an] = n-1
an = an1
print(list(islice(agen(), 63))) # Michael S. Branicky, Nov 14 2022
CROSSREFS
Sequence in context: A327042 A006168 A250115 * A287563 A184800 A350237
KEYWORD
nonn
AUTHOR
Scott R. Shannon, Nov 14 2022
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified July 23 04:43 EDT 2024. Contains 374544 sequences. (Running on oeis4.)