While(n>=1) { n=n/20; n=n/6; n=10×n; n=n-10000; }
I tried like this =>
In this cycle, N decreases by N / 12 - 10,000. Therefore, the time complexity is O (log N).
That seems right. If this is an exercise, you should be prepared to argue why O(log_12(N)) is O(log(N)) .
O(log_12(N))
O(log(N))