login
A376904
Inverse permutation to A376903.
3
1, 2, 4, 3, 11, 5, 26, 8, 6, 12, 82, 7, 97, 27, 13, 9, 202, 17, 244, 10, 28, 83, 424, 18, 14, 98, 46, 29, 664, 15, 741, 38, 84, 203, 16, 19, 1182, 245, 99, 39, 1416, 20, 1584, 85, 47, 425, 1923, 21, 30, 62, 204, 100, 2463, 22, 86, 31, 246, 665, 3354, 23, 3723
OFFSET
1,2
EXAMPLE
A376903(42) = 88, so a(88) = 42.
PROG
(C++) // See Links section.
(Python)
from itertools import count, islice
def agen(): # generator of terms; uses A376903gen() in A376903
adict, n = dict(), 1
for k, v in enumerate(A376903gen(), 1):
if v not in adict:
adict[v] = k
while n in adict: yield adict[n]; n += 1
print(list(islice(agen(), 61))) # Michael S. Branicky, Oct 16 2024
CROSSREFS
Cf. A376903.
Sequence in context: A093839 A248981 A096780 * A332454 A143986 A059662
KEYWORD
nonn
AUTHOR
Rémy Sigrist, Oct 09 2024
STATUS
approved