Sorted classes_taken

Just one small change. Sorts classes before outputting.