public short itemAt(int pos){
  if (pos < 0 || pos > state.length) {
    throw new IndexOutOfBoundsException();
  }
  for (; iter <= pos; ++iter) {
    int r=random.nextInt(state.length - iter) + iter;
    short tmp=state[r];
    state[r]=state[iter];
    state[iter]=tmp;
  }
  return state[pos];
}

public short itemAt ( int pos ) { if ( pos < 0 || pos > state . length ) { throw new IndexOutOfBoundsException ( ) ; } for ( ; iter <= pos ; ++ iter ) { int r = random . nextInt ( state . length - iter ) + iter ; short tmp = state [ r ] ; state [ r ] = state [ iter ] ; state [ iter ] = tmp ; } return state [ pos ] ; }
returns permutation element at a given position throws
