private double[thearrayprivate int nelems/ref to array thearray /number of data items //public arrayins(int max/constructor thearray new double[max]/create the array nelems /no items yet //public void insert(double value/put element into array thearray[nelemsvalue/insert it nelems++/increment size //public void display(/displays array contents system out print(" =")for(int = <nelemsj++/for each elementsystem out print(thearray[ ")/display it system out println("")//public void quicksort(recquicksort( nelems- )//public void recquicksort(int leftint rightif(right-left < /if size < return/already sorted else /size is or larger double pivot thearray[right]/rightmost item /partition range int partition partitionit(leftrightpivot)recquicksort(leftpartition- )/sort left side recquicksort(partition+ right)/sort right side /end recquicksort(