public static void main(String args[]){
		ExecutorService executor = Executors.newFixedThreadPool(2);
	
		for (int i=0;i<5;i++){
			executor.submit(new processor(i));
			
		}
		executor.shutdown();
		
		System.out.println("all tasks submitted");
		try {
			executor.awaitTermination(1, TimeUnit.DAYS);
		} catch (InterruptedException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
		System.out.print("all tasks completed");
		
	}