added loop counter back in for one of the questions.