Mine
public text v1 · immutable public static String getAlpha(int num) {
final int base = 26;
String results = "";
while (num > 0) {
int quo = new Double(Math.floor(num / base)).intValue();
results = (char)(num % base + 65) + results;
num = quo;
}
if (results.length() == 1) {
return results;
}
char[] res = results.toCharArray();
res[0]--;
return new String(res);
}