Saturday, July 31, 2010

Is stdlib's qsort recursive?

Programmer Question

I've read that qsort is just a generic sort, with no promises about implementation. I don't know about how libraries vary from platform to plaform, but assuming the Mac OS X and Linux implementations are broadly similar, are the qsort implementations recursive and/or require a lot of stack?



I have a large array (hundreds of thousands of elements) and I want to sort it without blowing my stack to oblivion. Alternatively, any suggestions for an equivalent for large arrays?



Find the answer here

No comments:

Post a Comment

LinkWithin

Related Posts with Thumbnails