书中第六章 136页的代码:
public class UseCar {
public static void main(String[] args) {
Car carPassedBy;
carPassedBy = new Car();
carPassedBy.speed = 60;
carPassedBy.color = "白色";
carPassedBy.name = "雪铁龙一号";
carPassedBy.direction = "镇江方向";
System.out.println("经过的汽车的速度为:" + carPassedBy.speed);
System.out.println("它的颜色是:" + carPassedBy.color);
System.out.println("汽车的名字叫做:" + carPassedBy.name);
System.out.println("汽车行驶方向:" + carPassedBy.direction);
}
}
输入进去的时候,显示 “sprrd” "color" name direction 下面都有红线 ,这是哪里出现问题了啊,我刚学的JAVA |