OFFSET
0,3
COMMENTS
A permutation of the nonnegative integers: all terms are distinct; if all the values up to v >= 0 with the same parity as v have appeared, v+2 necessarily appears, at the latest, as the first child of v; as the sequence contains 0 (respectively 1), it contains every even numbers (respectively every odd numbers).
LINKS
Rémy Sigrist, Table of n, a(n) for n = 0..10001
Rémy Sigrist, PARI program
EXAMPLE
The first terms, arranged as two binary trees, are:
____0____ ____1____
| | | |
__2_ __3_ __4_ __6_
| | | | | | | |
5 7 8 10 9 11 13 17
PROG
(PARI) \\ See Links section.
CROSSREFS
KEYWORD
nonn,new
AUTHOR
Rémy Sigrist, Jul 08 2026
STATUS
approved
