
java中运行程序是出现一个对话框,选择java applet出现一个提示:selection dose not contain an applet?
publicclassTestextendsTT{publicvoidmain(Stringargs[]){Testt=newTest("Tom");}publicTes...
public class Test extends TT { public void main(String args[]) { Test t = new Test("Tom"); } public Test(String s) { super(s); System.out.println("How do you do?"); } public Test() { this("I am Tom"); } } class TT{ public TT(){ System.out.println("What a pleasure!"); } public TT(String s) { this(); System.out.println("I am" + s); } } 这是程序,各位大侠帮忙解决一下
public class Test extends TT
{
public void main(String args[])
{
Test t = new Test("Tom");
}
public Test(String s)
{
super(s);
System.out.println("How do you do?");
}
public Test()
{
this("I am Tom");
}
}
class TT{
public TT(){
System.out.println("What a pleasure!");
}
public TT(String s)
{
this();
System.out.println("I am" + s);
}
} 展开
public class Test extends TT
{
public void main(String args[])
{
Test t = new Test("Tom");
}
public Test(String s)
{
super(s);
System.out.println("How do you do?");
}
public Test()
{
this("I am Tom");
}
}
class TT{
public TT(){
System.out.println("What a pleasure!");
}
public TT(String s)
{
this();
System.out.println("I am" + s);
}
} 展开
1个回答
展开全部
main方法错了
public static void main(String args[])
public static void main(String args[])
本回答被提问者采纳
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询