Refactor for loop to take out first if statement. Make 'first' equal to 'current' before for loop.