public class Caller { //Driver class creates & uses the Range iterator public static void main(String args[]) { Range ran = new Range(5, 15); while(ran.hasNext()) System.out.println("Value "+ran.next()); } }