void (int index) { if (index < 0) throw new IndexOutOfBoundsException("index is " + index + " which is less than zero"); if (index >= mySize) throw new IndexOutOfBoundsException("index is " + index + " and set size is " + mySize); }