最赞回答 / 清栀12138
public class HelloWorld{ public static void main(String[] args) { int one = 10 ; int two = 20 ; int three = 0 ; three = one + two; //three = 10+20,所以three是30; System.out.println("three = one + two ==> " + three); ...
2020-06-23
已采纳回答 / 溺水的鲨鱼
这个运算符的问题,因为没有40<age<60这种写法,如果要让他大于40并且小于60的话需要用运算符&&连接,也就是这样:40<age&&age<60
2020-06-23
已采纳回答 / qq_慕斯卡2160049
char只能储存一个字符,就是说只能储存一个字母,汉字或者数字,比如你写的boy是3个字母,你可以把boy改为男,girl改为女,这样就对了
2020-06-23
public class HelloWorld{
public static void main(String[] args) {
int rise=5;
double avg1=78.5;
double avg2=avg1+rise;
System.out.println("考试平均分:"+avg1);
System.out.println("调整后的平均分:"+avg2);
}
}
public static void main(String[] args) {
int rise=5;
double avg1=78.5;
double avg2=avg1+rise;
System.out.println("考试平均分:"+avg1);
System.out.println("调整后的平均分:"+avg2);
}
}
2020-06-17
最新回答 / 徐世民
import java.util.Arrays;public class HelloWorld { //完成 main 方法 public static void main(String[] args) { int[]scores={89,-23,64,91,119,52,73}; System.out.println("考试成绩的前三名是:"); HelloWorld hello=new HelloWorld(); ...
2020-06-15