/*
 * This File is one of the examples from Java Application Development
 * Do not reproduce this code for others or use it in a commercial setting without prior permission from the author.
 */

package tasks;

/**
 *
 * @author Matthew Gregory
 * @website www.matthewgregory-author.com.au
 *
 */
public class Task implements Runnable {
    public void run(){
        for (int i=1;i<=100;i++){
//            System.out.println("Number: "+i);
            System.out.println("Number: "+i
                               +" Processed by: "
                               +Thread.currentThread().getName());
//            try{
//                Thread.sleep(10);
//            } catch (InterruptedException ex) {
//                System.out.println(Thread.currentThread().getName()+" was interrupted.");
//            }
            TakeABreak.sleep();
        } 
    }
}
