Page 10 - Data Structures Interactive Book
P. 10

9.7.2  Memory Usage .............................................................................................. 117


                          9.7.3  Security Concerns with Weak Hash Functions ............................................. 118

                        9.8    Summary .............................................................................................................. 118


                        9.9    Exercise ................................................................................................................ 120

                     CHAPTER 10  SORTING ALGORITHMS ...................................................................... 122


                       10.1  Introduction to Sorting ......................................................................................... 123

                          10.1.1  Importance and Applications ........................................................................ 123


                          10.1.2  Real-World Example in C++ ........................................................................ 124

                          10.1.3  Comparison of Sorting vs Searching ............................................................ 124


                       10.2  Basic Sorting Methods ......................................................................................... 125

                          10.2.1  Bubble Sort ................................................................................................... 125


                          10.2.2  Selection Sort ................................................................................................ 126

                          10.2.3  Insertion Sort ................................................................................................. 127


                       10.3  Advanced Sorting Methods .................................................................................. 128

                          10.3.1  Merge Sort .................................................................................................... 128


                          10.3.2  Quick Sort ..................................................................................................... 129

                          10.3.3  Heap Sort ...................................................................................................... 130


                       10.4  Non-Comparison Sorting ..................................................................................... 132

                          10.4.1  Counting Sort ................................................................................................ 132


                          10.4.2  Radix Sort ..................................................................................................... 133

                       10.5  Performance Analysis .......................................................................................... 135


                         10.5.1  Time and Space Complexity ......................................................................... 135

                         10.5.2  Stability of Sorting Algorithms ..................................................................... 135


                       10.6  Applications of Sorting ........................................................................................ 136

                       10.7  Limitations of Sorting .......................................................................................... 136





                                                             10
   5   6   7   8   9   10   11   12   13   14   15