hostcounter=1 for a in range-of-a do for b in range-of-b do for c in range-of-c do some stuff with a b and c done done increment hostcounter by 1 check if hostcounter is 90 if hostcounter is 90, set hostcounter to 1 again done