Worst Case: O(n^2), when the condition if (woo == 10000) is never satisfied, and the inner loop runs fully for every i.
Best Case: O(n^2), when the condition is met on the first iteration of the inner loop, causing an early exit from the if condition but the for inner for loop will execute for the complete iteration(all values of i).