String alphabet = "ABCDEFGHIJKLMNOPQRSTUVWXYZ";int indexOfLetterD = alphabet.indexOf("D");//indexOfLetterD equals 3
String middle3 = (string.length() < 3) ? null :
string.substring(string.length() / 2 - 1, string.length() / 2 + 2);
String middle3 = (string.length < 3) ? null : string.substring(string.length / 2 - 1), string.length / 2 + 2);
for (int i = 'A'; i <= 'Z'; i++)
for (fileName: fileNameList) {
if ((int)fileName.charAt(0) == i) {
AlphabetList.add((char)i);
}
}
}