List<Move> moveList = new ArrayList<Move>();
for (ListIterator<Exam> leftIt = examList.listIterator(); leftIt.hasNext();) {
Exam leftExam = leftIt.next();
for (ListIterator<Exam> rightIt = examList.listIterator(leftIt.nextIndex()); rightIt.hasNext();) {
Exam rightExam = rightIt.next();
moveList.add(new ExamSwapMove(leftExam, rightExam));
}
}
return moveList;
}