day07 learning

long a = 12121221321L;
int b= 123;
short c = 10;
byte d = 8;
System.out.println(a+b+c+d); //int
System.out.println(b+c+d); //int
System.out.println(c+d); //int
// 当一串数字操作时,有long最大那就是long 类型,没有long,double 就是int 类型,有double 就是double ,double 最大

posted @ 2020-10-18 23:37  Strive_ToLife  阅读(74)  评论(0编辑  收藏  举报