f(84) = 997
Correct. Solution?
I solved for f(n) 990 <= n <= 1000, since all values < 1000 end up hitting f(99*) somewhere. After doing the first 4 I saw a pattern of f(odd) = 998, f(even) = 997, so f(84) = 997. There's probably a better way I could have done it, but I don't care much, and the calculations took about 45 seconds all told, so I'm happy