- chuyện thế này các bác ạ:
- em có 1 arrlist chứa kiểu dữ liệu là 1 class student, em muốn sắp xếp tên theo từ diển mà không được các bác giúp em với nó báo lỗi.
public static void sortedStudent(ArrayList<studentCollege> liStudentColleges) {
Collections.sort(liStudentColleges, new Comparator<String>() {
@Override
public int compare(String s1, String s2) {
return s1.compareToIgnoreCase(s2);
- các bác giúp em với em cám ơn!
83% thành viên diễn đàn không hỏi bài tập, còn bạn thì sao?