5. EXAMPLE OF LSD-RADIX SORT 05 Input is an array of 10 integers. For integers, the number of buckets is 10, from 0 to 9. The first pass distributes the keys into buckets by the least significant digit (LSD). When the first pass is done, we have the following. Initial Array We collect these, keeping their relative order: 13 34 42 32 44 11 23 87 08 58 0 1 2 3 4 5 6 7 8 9 11 42 13 34 87 58 32 23 44 08 11 42 32 13 23 34 44 87 58 08
6. WINTER Template 06 Now we distribute by the next most significant digit, which is the highest digit in our example, and we get the following. EXAMPLE CONTD………….. Sorted Array 0 1 2 3 4 5 6 7 8 9 08 11 23 32 42 58 87 13 34 44 08 11 13 23 32 34 42 44 58 87