public class UseBox
{
    public static void main( String[] args ) 
    {
	StuffBox theBox = new StuffBox(20);

	//put stuff in box
	theBox.addStuff(10);
	theBox.addStuff(13);
	theBox.addStuff(7);


	try
	    {
		//demonstrate getting stuff from box works
		System.out.println("Box 0: " + theBox.getStuff(0));
		System.out.println("Box 1: " + theBox.getStuff(1));
		System.out.println("Box 2: " + theBox.getStuff(2));
		
		System.out.println();
	
		//this line causes the error
		System.out.println("Box 3: " + theBox.getStuff(3));
		
	    }
	catch(StuffBoxException dave)
	    {
		System.out.println(dave);
	    }


    }

}
