Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Part 1: Sorting For this part, you will implement five sorting algorithms: Heaps

ID: 3645879 • Letter: P

Question

Part 1: Sorting
For this part, you will implement five sorting algorithms: Heapsort, Merge Sort, Quicksort,
Radix sort, and some other sort (see below). Since Radix Sort is not a general purpose sort,
generics aren't for a fair comparison in the second part. As such, you can simply implement all
five as integer sorters. As such, each will receive an array of integers, and sort the values within
the array.
For the fifth sort, you may implement whichever deterministic sort that's guaranteed to
finish/work that you like (that isn't already one of the four listed, of course). Suggestions include:
Bubble Sort or Selection Sort. There's no need to choose a 'good' sort, as a 'bad' one will simply
make the second part of this assignment more interesting.
Bonus: The radix sort mentioned above will use integers. However, it can also be used with
letters. For a bonus, implement a radix sort that takes an array of Strings, and sorts them
lexicographically. You may assume that only letters will be used (eg. a, j, L, z. No numbers,
punctuation, or spaces), but you must treat uppercase and lowercase as being equivalent (ie. a
doesn't have a higher priority than A, and vice versa).
Note: This is more complicated than it initially seems!

Explanation / Answer

its tooooo lengthy dear :((