class Car
{
private int num;private String color;
Car(num,color)
{
this.num = num;
this.color = color;
}
void run()
{
System.out.print(num+"..."+color);
}
}
class Xing
{
public static void main(String[] args)
{
Car c1 = new Car(3,"red");
c1.run();
}
}这个代码哪里有问题呀
{
private int num;private String color;
Car(num,color)
{
this.num = num;
this.color = color;
}
void run()
{
System.out.print(num+"..."+color);
}
}
class Xing
{
public static void main(String[] args)
{
Car c1 = new Car(3,"red");
c1.run();
}
}这个代码哪里有问题呀