Skip to content

递归与非递归的快速排序#22

Open
YSoiiiiii wants to merge 1 commit intoxiufengcheng:masterfrom
YSoiiiiii:patch-3
Open

递归与非递归的快速排序#22
YSoiiiiii wants to merge 1 commit intoxiufengcheng:masterfrom
YSoiiiiii:patch-3

Conversation

@YSoiiiiii
Copy link
Copy Markdown
Contributor

@YSoiiiiii YSoiiiiii commented Dec 15, 2017

递归转化为非递归的基本思想就是用一个栈来模拟函数调用中的压栈退栈过程。
我写的比较简单,效率应该还不如用递归的方法。不过只要算法是一致的,该存的数据还是要存,基本省不了空间;再加上现在64位处理器的函数调用的代价比较小,也很难省下时间。

———李梓同

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant