Java - Sort an array with Extreme Minimum or maximun values : I want to get the maximum or minimum values from an Arraylist.

For example I have follwing values in my Arraylist,
1.22 , 2.55 , 6.00 , 3.00 , 4.77 , 9.88 , 7.23 , 8.22 

I would like to get it sorted like

9.88, 1.22 , 8.22 , 2.55 , 7.45 ... ... ...


Currently i am sorting the values in decessending order using following code,

    Collections.sort(characterPairs, new Comparator<Pair<String, Double>>() {

            @Override
            public int compare(Pair<String, Double> o1, Pair<String, Double> o2) {
                if(o1.second>o2.second)
                    return -1;
                if(o1.second<o2.second)
                    return 1;
                return 0;
            }
        });
