阅读程序,写出该程序的输出结果。
public class Test31 implements Runnable{
private int assignment=6;
public void run(){
while(true){
try{
Thread.sleep(1);
}catch(InterruptedException e){
e.printStackTrace();
}
synchronized(this){
if(assignment>0)
System.out.println(Thread.currentThread().getName()+
":send"+(assignment--)+"# paper");
else
break;
}
}
}
public static void main(String[]args){
Test31t31=new Test31();
new Thread(t31,"T").start();
}
}