OFFSET
1,3
COMMENTS
This is the lexicographically earliest sequence that together with its first differences (A274688) contains every integer except 0 exactly once.
Each term is chosen so that |a(n)| is minimal such that neither a(n) nor (a(n) - a(n-1)) has occurred previously in either this sequence or this sequence's first differences.
EXAMPLE
a(1) = 1; the next number with the lowest possible absolute value that has not occurred yet is -1. -1 - (1) = -2, which also has not yet occurred, so a(2) = -1. The next available term is 2. 2 - (-1) = 3, which is also available, so a(3) = 2.
CROSSREFS
KEYWORD
sign
AUTHOR
Max Barrentine, Jul 02 2016
STATUS
approved