Syntax doubt (placement of 'i')

Updation in ‘i’ should be under print i or it will be under while