are passed to the recursive calls in lines and of listing using the proper index ranges after the recursive callsthe recquicksort(function returns in the earlier descriptionthe sorted segments and pivot value had to be merged and stored back into the original sequence but since we are using virtual segmentsthe keys are already stored in their proper position upon the return of the two recursive calls to help visualize the operation of the partitionseq(functionwe step through the first complete partitioning of the sample sequence the function begins by saving copy of the pivot value for easy reference and then initializes the two index markersleft and right the left marker is initialized to the first position following the pivot value while the right marker is set to the last position within the virtual segment the two markers are used to identify the range of elements within the sequence that will comprise the left and right segments first last left right the main loop is executed until one of the two markers crosses the other as they are shifted in opposite directions the left marker is shifted to the right by the loop in lines and of listing until key value larger than the pivot is found or the left marker crosses the right marker since the left marker starts at key larger than the pivotthe body of the outer loop is not executed if theseq is empty left right after the left marker is positionedthe right marker is then shifted to the left by the loop in lines and the marker is shifted until key value less than or equal to the pivot is located or the marker crosses the left marker the test for less than or equal allows for the correct sorting of duplicate keys in our examplethe right marker will be shifted to the position of the left right the two keys located at the positions marked by left and right are then swappedwhich will place them within the proper segment once the location of the pivot is found left right