I want to use a Thread that sorts a list with my method quicksort.
Unfortunately I dont know how to do that.
------------------
blabla other Methodes that quicksort/ sort needs....
------------------
public static void sort(int[] list) {
quickSort(list, 0, (list.length-1)); // <--- I want use this in a Thread
}
public static void main (String[] args) {
int[] newList = {5, 7, 23, 87, 11, 0, 5, 33, 30,512, 125, 215 ,7, 234, 152, 125};
for(int i: newList) {
System.out.print(i + " ");
}
System.out.println();
sort(newList); // <--- OR I want use this in a Thread
My Problem is that I dont know how to use a Method with Parameters in a Thread.
Does someone know a good Tutorial that explains me how to do that?
What better implement Runnable or extends Thread?