Array array = new Array(); array.add( "ape" ); array.add( "cat" ); try { Object object = array.at( 5 ); } catch ( IndexOutOfBoundsException exception ) { System.out.println( "Caught " + exception ); }