posted 15 years ago
Please let me know how to sort the data in the below array list.
I know that we can put A4.get(0) and A4.get(1) in TreeSet and sort the list, but can the list be sorted just using above code like,
I used Collections.sort(A4) it is giving wrong results. Also, while using Collections.sort(A4), is the list sorted by taking A4.get(0) as a reference or A4.get(1) as reference.
Please let me know>