sec binsort and radix sort initial list first pass (on right digitsecond pass (on left digit result of first passresult of second pass figure an example of radix sort for twelve two-digit numbers in base ten two passes are required to sort the list of in other wordsassign the ith record from array to bin using the formula [ ]/ if we now gather the values from the bins in orderthe result is sorted list figure illustrates this process in this examplewe have bins and keys in the range to the total computation is th( )because we look at each record and each bin constant number of times this is great improvement over the simple binsort where the number of bins must be as large as the key range note that the example uses so as to make the bin computations easy to visualizerecords were placed into bins based on the value of first the rightmost and then the leftmost decimal digits any number of bins would have worked this is an example of radix sortso called because the bin computations are based on the radix or the base of the key values this sorting algorithm can be extended to any number of keys in any key range we simply assign records to bins based on the keysdigit values working from the rightmost digit to the leftmost if there are digitsthen this requires that we assign keys to bins times