Fixed up algorithms: should be robust now.

groups of size N (or greater), and
N groups of nearly-equal size.
Submitting a mark now closes the window showing a student's name