package IteratorHelper; import java.io.BufferedReader; import java.io.InputStreamReader; public class ConsumerProducerGood { public static void main (String [] args) { //Buffer buf = new Buffer(); // create new threads Thread prod = new Producer(); Thread cons = new Consumer(); InputStreamReader ISR = new InputStreamReader(System.in); BufferedReader BR = new BufferedReader(ISR); int low = 0; int high= 0; try { // output the question. System.out.print("Enter value for low : "); // read in the console input one line (BR.readLine) and then convert to a integer low = Integer.parseInt(BR.readLine()); System.out.print("Enter value for high : "); high = Integer.parseInt(BR.readLine()); for (int i=low;i