A Compact Guide to Sorting and Searching |
| This is a collection of algorithms for sorting and searching. Descriptions are brief and intuitive, with just enough theory thrown in to make you nervous. I assume you know a high-level language, such as C, and that you are familiar with programming concepts including arrays and pointers.
|
Various Sorting Algorithms C Source Code |
| Download a collection of various sorting algorithms in C |
Various Sorting Algorithms Visual Basic Source Code |
| Download a collection of various sorting algorithms in VB |
Bubble Sort Algorithm |
| Bubble Sort is an elementary sorting algorithm. It is so inefficient that it should never be used in practice. What makes it inefficient is the excessive number of exchanges that it performs. Much time is wasted by needlessly moving data in memory.
|
Elementary Sorting Algorithms |
| Sorting algorithms are often subdivided into "elementary" algorithms that are simple to implement compared to more complex algorithms that, while more efficient, are also more difficult to understand, implement, and debug.
|
Shell Sort Algorithm |
| Shell Sort is the first sorting algorithm we'll look at that requires fewer than O(N2) comparisons and exchanges, on average. Although it is easy to develop an intuitive sense of how this algorithm works, it is very difficult to analyze its execution time.
|
Comparison of Sorting Algorithms |
| The following table summarizes the basic strategies used in various sorting algorithms, and lists the algorithms that use these strategies.
|