How to sort an array in reverse order using java?
<pre><code>package javaLearning;
import java.util.Arrays;
import java.util.Collections;

    public class myarray {

         public static void name() {
         String hello;
         hello = "hello, world";
         int hello_len = hello.length();
         char[] hello_array = new char[hello_len];
         hello.getChars(0, hello_len, hello_array, 0);
         Arrays.sort(hello_array, Collections.reverseOrder());
}
</code></pre>

<p>the "myarray" class is defiend in a main method of a testing class.
why does it give me a compile error when I try reversing the array?</p>
