What is the expected number of steps in the following process?

Here are some results for very small numbers, when there are $n$ variables: $$ \begin{align*} f(1,1,1,\ldots,1) &= 1, \\ f(2,1,1,\ldots,1) &= \frac{n}{n-1}, \\ f(3,1,1,\ldots,1) &= \frac{n^3-2n^2+3n}{n^3-3n^2+4n-2} = \frac{n}{n-1} \cdot \frac{n^2-2n+3}{n^2-2n+2}, \\ f(2,2,1,\ldots,1) &= \frac{n^3-n^2+2n}{n^3-3n^2+4n-2} = \frac{n}{n-1} \cdot \frac{n^2-n+2}{n^2-2n+2}. \end{align*} $$