-
Notifications
You must be signed in to change notification settings - Fork 188
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
归并排序 #109
Comments
你在自底而上归并排序里面对于空间复杂度的分析有问题! |
那个手摇算法在leetcode上面使用,我觉得可以填上去。 |
文章下面的手摇算法就节省了辅助数组的空间。如果没有原地排序,你确实可以说空间复杂度是O(N),但是根据上下文,我们讨论的是两种方法的区别,空间上的复杂度只要考虑的是递归,自顶向下空间复杂度更大。 |
实际上,不是leetcode有用,你要明白这一点。 |
https://hunterhug.github.io/goa.c/#/algorithm/sort/merge_sort
Description
The text was updated successfully, but these errors were encountered: