0
example for sorting list
import java.util.ArrayList; import java.util.Collections; public class MyClass { public static void main(String[ ] args) { ArrayList<String> animals = new ArrayList<String>(); animals.add("Dog"); animals.add("cat"); animals.add("Cheetha"); animals.add("Tiger"); Collections.sort(animals); System.out.println(animals); } }
1 ответ
+ 2
yes definitely