请帮忙哈
public class Point
{
int x,y;
Point()
{ this(12,15);
}
Point(int a,int b)
{
x=a;
y=b;
}
void getpoint()
{
System.out.println("点("+x+","+y+")");
}
void getpoint(int c,int d)
{
x=c;
y=d;
System.out.println("点("+x+","+y+")");
}
public static void main(String [] args)
{
Point p1=new Point();
Point p2=new Point(10,20);
p1.getpoint();
p1.getpoint(15,20);
p2.getpoint();
p2.getpoint(25,30);
}
}跪求谁帮忙调试哈,它总是提示找不到main class
------解决方案--------------------代码没有错
public class Point
{
int x,y;
public Point()
{ this(12,15);
}
Point(int a,int b)
{
x=a;
y=b;
}
void getpoint()
{
System.out.println("点("+x+","+y+")");
}
void getpoint(int c,int d)
{
x=c;
y=d;
System.out.println("点("+x+","+y+")");
}
public static void main(String [] args)
{
Point p1=new Point();
Point p2=new Point(10,20);
p1.getpoint();
p1.getpoint(15,20);
p2.getpoint();