读书人

快点进来看看吧~回答得好小弟我就给你

发布时间: 2011-12-26 23:09:59 作者: rapoo

快点进来看看吧~~~回答得好我就给你分
class robot{
String status;
double speed;
double temperature;

void checktemperature(){
if(temperature>600){
speed=5;
status="return home!";
}
}
void showattitude(){
System.out.println("status:"+status);
System.out.println("speed:"+speed);
System.out.println("temperature"+temperature);
}

public static void main(String[] args){
robot henry=new robot();
henry.status="exploring";
henry.speed=3.33;
henry.temperature=300.2;

henry.showattitude();
System.out.println("increase his temperature to 700.333");
henry.showattitude();
System.out.println("check his temperature");
henry.checktemperature();
henry.showattitude();
}
}为什么运行不了呢?

[解决办法]
我运行的好好的
[解决办法]

探讨
引用:

引用:

引用:

最近飞机打多了记忆力下降

你的小猴子图标怎么弄的呀~

读书人网 >J2SE开发

热点推荐