Java równolegle

//for big data we can use multiple threads for faster sorting
int[] arr={1,2,3,4,5,2,4};
//using parallelsort()
Arrays.parallelSort(arr);
//using stream
int[] arr=Arrays.stream(arr)
  .parallel()
  .sorted()
  .toArray();
Itachi