Completed foreach exercises.