# [Vyxal](https://github.com/Vyxal/Vyxal), 7 bytes ``` ≬K÷εẋL‹ ``` [Try it Online!](https://vyxal.pythonanywhere.com/#WyIiLCLJvihu4oK0YCA9PiBg4oK0bjoiLCLiiaxLw7fOteG6i0zigLkiLCIsKSIsIjExMSJd) Ties with [Steffan's answer](https://codegolf.stackexchange.com/a/249836/17216), but uses the algorithm defined by the challenge: ``` ≬ # 3-element lambda: K # Push a list of the divisors, from 1 to the number itself in increasing order ÷ # Unwrap the list onto the stack ε # Absolute difference of the last two items (this will be the largest two) ẋ # Repeat the lambda on the number at the top of the stack (which is initially the # input) until the result no longer changes, returning a list of the results. The # last result will be zero, because the list of divisors of the penultimate result, # 1, is just ⟨1⟩, but ε will subtract that 1 from itself. L # Length ‹ # Decrement - subtract 1 ``` `-` also works in place of `ε`, i.e. `≬K÷-ẋL‹`. The sign of the intermediate result keeps flipping, since the subtraction is done in the "wrong" direction, but the number of steps to get to zero is the same. Alternative 7 byter: ``` ≬K¯tẋL‹ ``` [Try it Online!](https://vyxal.pythonanywhere.com/#WyIiLCLJvihu4oK0YCA9PiBg4oK0bjoiLCLiiaxLwq904bqLTOKAuSIsIiwpIiwiMTExIl0=) Only the lambda is different in this: ``` K # Push a list of the divisors, from 1 to the number itself in increasing order ¯ # Deltas (consecutive differences) t # Tail - get the last item of the list ``` This still takes one more step than we want, requiring the `‹` decrement, because `t` tail returns zero for an empty list. And even if it returned something else (such as empty list), the fixed point would still be that result, and not 1, thus still requiring the decrement.