4 ms·
The solution on the solutions wiki solves the problem by building a heap data structure and then removing the k smallest elements. That seems to be correct. W
by drallison 11y ago
The solution on the solutions wiki solves the problem by building a heap data structure and then removing the k smallest elements. That seems to be correct. Why do you believe this to be incorrect?