oops, increment index when generating assignments