一、求 两个数 30.30 和 40 的最大值?
public class Ex0031 {
public static void main(String[] args) {
double a = 30.03;
int b = 40;
double max = a;
if(max < b){
max = b;
}
System.out.println("最大值是 :" + max);
}
}
一、求 两个数 30.30 和 40 的最大值?
public class Ex0031 {
public static void main(String[] args) {
double a = 30.03;
int b = 40;
double max = a;
if(max < b){
max = b;
}
System.out.println("最大值是 :" + max);
}
}