アットウィキロゴ

pro0610

class pro0610 extends Thread{

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

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