FileDocCategorySizeDatePackage
Counters.javaAPI DocExample1467Mon Oct 16 19:44:06 BST 2000None

Counter1

public class Counter1 extends Thread

Fields Summary
private int
myId
private int
count
Constructors Summary
public Counter1(int id)

  myId = id;
   
Methods Summary
public voidrun()

     
     while( count < 1000000 )
      {  count++;
         if(  (count % 50000) == 0 )
         { System.out.println( "Thread: " + myId + " count --> " + count );
         }
     }