One can transform \(x\) into \(x + d\) if \(d\) is divisor of \(x\). Find out the minimum number of steps to transform \(a\) into \(b\).
Two integers \(a\) and \(b\).
(\(1 \leq a, b \leq 10^5\))
The only integer denotes the minimum number of steps. Print \(-1\) if impossible.
1 6
3
\(1 \to 2 \to 4 \to 6\) or \(1 \to 2 \to 3 \to 6\).