Setting For Loop

setting conditional for For Loop