public class example3
{
public static void main(String[] args)
{
double x = 6.8;
int i, j;
j = (int) (x + 1.3);
i = (int) x + (int) 1.3;
System.out.println("i = " + i);
System.out.println("j = " + j);
}
}
example 4-3 Type Cast JAVA强制类型转化
最新推荐文章于 2021-11-30 08:50:04 发布