public class RunnableTest implements Runnable {
private String name;
public RunnableTest(String name){
this.name = name;
System.out.println(name+“创建”);
}
public void run() {
for(int i=0;i<4;i++){
System.out.println(name+“运行:”+i);
}
System.out.println(name+“结束”);
}
}