finalize the assignment.