|
|
submitted by
igoro
2 months, 30 days ago
igoro.com — Quicksort usually runs in O(N log N) time, but in special cases, it takes much longer: O(N^2). It is surprisingly easy to force any quicksort implementation to degrade into the quadratic-time behavior. This trick even works against a randomized quicksort! The article demonstrates how the trick works by applying it against the BCL Array.Sort() routine.
|
|
tags:
CodeThinked, Algorithms, C#, .Net | tag it
Everyones tags: | Your tags: | |
|
|
|
Add a live kick counter to your blog >>
You can even customize the image by choosing your own colors, and then clicking
the button below to update the preview and the html code:
Simply copy and paste this HTML into your blog post.
Users who kicked this story:
No comments so far
|