CPSC 220
Fall 2005
HW 4: More Quicksort

  1. Consider the array a of integers below:
    2  4  5  6  7  8  9 
    
    Trace the operation of quicksort on this array. Show all recursive calls; for each call show the parameters and the return value, and indicate any changes that are made in the array.

  2. Consider the array a of integers below:
    6  5  2  7  8  9  4
    
    Trace the operation of quicksort on this array. Show all recursive calls; for each call show the parameters and the return value, and indicate any changes that are made in the array.