アットウィキロゴ

pro0609

class pro0609 extends Thread{

public void run() {
int n;
  for(n = 1; n < 10; n++) { 
    System.out.println(n); 
    try {sleep([[100]]); } 
catch (InterruptedException e) { }
  } 
} 

public static void main(String[] args){ 
  pro0609 th1 = new pro0609(); 
  pro0609 th2 = new pro0609(); 
  th1.start(); 
  th2.start(); 
} 
}
最終更新:2010年09月17日 17:27