## Octave, 55 bytes, 10 numbers, [flawr](http://codegolf.stackexchange.com/a/99669/30688) (o=@(O,o)(@(O,o)o{2-O} ) (0<O,{ (yo=O-1)+1,@()1}))(1,o) The final `1` can be cycled up to 9, and then change the `+1` to `+2`.