updated goal1_duel1

updated the function so that it’s no longer declaring the function
every time in the loop