swap(leftptrrightptr)/end while(trueswap(leftptrright- )/swap elements return leftptr/end partitionit(/return pivot location /restore pivot //public void manualsort(int leftint rightint size right-left+ if(size < return/no sort necessary if(size = / -sort left and right ifthearray[leftthearray[rightswap(leftright)returnelse /size is / -sort leftcenter (right- right ifthearray[leftthearray[right- swap(leftright- )/leftcenter ifthearray[leftthearray[rightswap(leftright)/leftright ifthearray[right- thearray[rightswap(right- right)/centerright /end manualsort(///end class arrayins ///////////////////////////////////////////////////////////////class quicksort app public static void main(string[argsint maxsize /array size arrayins arr/reference to array arr new arrayins(maxsize)/create the array for(int = <maxsizej++/fill array with /random numbers double (int)(java lang math random()* )arr insert( )arr display()/display items arr quicksort()/quicksort them