Move constant out of loop