You are viewing a single comment's thread. Return to all comments →
for a test case n == k wont the line
int mustWinImprCount = importantContests.size() - k;
cause a problem, Since Arraylist size is less than n, the variable mustWinImprCount will be initialized with negative value causing the for loop to cease in the beginning?