Hacker News new | past | comments | ask | show | jobs | submit login

You can use `heapq` from the standard library to at least go from `n k log k` to `n log k`.



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: