Java 8 support clarification

I tried to submit code for 2 problems which involved sorting(ANUBTG,COOLING).In both cases,I got a compilation error when I tried to use Arrays.parallelSort().
The same code runs perfectly on the ide provided by codechef and my laptop having java 8.

Parallel Sort is a new function action added in java 8.I tried to run it since it is 2 times faster than Arrays.sort()(acc. to [this][1] blog)

I tried to use it for first time today .My question to the admin is whether these are temporary changes because of yesterday’s problem during Cook Off?

link to my


Screenshots: 1.compilation [error][3] 2.program running on codechef's [ide][4]  


I submitted the code with parallelSort. No compilation error appeared for me.

Did the compilation specifically mention that parallelSort was not defined in class Arrays?

Oh god. You have named your class containing main as anubtg. That doesn’t work. It has to be named Main. You could check the compliation error by clicking on the error icon after submission.

yes see the screenshot
It says Cannot find Symbol
Symbol: method parallelSort(int[])
Class: Arrays

And as you can see in my code I have imported java.util.*; and your code has java.util.Arrays;

and when I use Arrays.sort() I get an AC

@asr21: its parallelSort and not parellelSort

1 Like

Okay I changed it to parallelSort() and it ran
But take this solution It also got an Compilation error but this time it was parallelSort as you are saying


I guess it is not working for old problems like cooling pies

@asr21 They probably use the Java 7 compiler. And please try compiling your code before posting on the forum. :stuck_out_tongue: How can the ide work when the spelling is wrong.

Well spotted @ashes45. (y)