timing within a loop

the first half of the code i only want to run once

Define "half"'