62,620
社区成员
发帖
与我相关
我的任务
分享
public class DtoH {
public static void main(String[] args) {
toHex(60);
}
public static void toHex(int num) {
for(int x=0; x<8; x++) {
int temp = num & 15;
if(temp>9)
System.out.println((char)(temp-10+'A')); //????
else
System.out.println(temp);
num = num >>> 4;
}
}
}
temp-10+'A'这段代码是什么意思呢?