moving assignments to the end