I have List list1 in direct order. List list = Ordering.natural().sortedCopy(asu2);
List list = Ordering.natural().sortedCopy(asu2);
How to change order. And I don\'t know how to rewrite
Use this:
Collections.reverse(list);
How I would do it is:
personsList.sort(Comparator.comparing(Person::getAge, Comparator.reverseOrder()));
And happy coding :)