import java.applet.*;
import java.awt.Graphics;/**
* @author qiao
*
* TODO 要更改此生成的类型注释的模板,请转至
* 窗口 - 首选项 - Java - 代码样式 - 代码模板
*/
public class A extends Applet implements Runnable
{ int j,k;
Graphics p;
Thread t;
public void run() {
for(int i=10;i<=99;i+=10)
{
p.drawRect(i,i,i,i);
try
{
t.sleep(600);
}
catch( Exception e){}
}
}
public void init()
{
p=getGraphics();
t=new Thread(this);
}
public void start()
{
t.start();
}}
import java.awt.Graphics;/**
* @author qiao
*
* TODO 要更改此生成的类型注释的模板,请转至
* 窗口 - 首选项 - Java - 代码样式 - 代码模板
*/
public class A extends Applet implements Runnable
{ int j,k;
Graphics p;
Thread t;
public void run() {
for(int i=10;i<=99;i+=10)
{
p.drawRect(i,i,i,i);
try
{
t.sleep(600);
}
catch( Exception e){}
}
}
public void init()
{
p=getGraphics();
t=new Thread(this);
}
public void start()
{
t.start();
}}
super.start();
}
at 线程.A.run(A.java:31)
at java.lang.Thread.run(Thread.java:595)
这就是错误代码