added a nested loop to wk1 resubmit