The general syntax of a do loop is:
$[\langle name\rangle :]$ do $\langle exec\_stmts\rangle$ end do $[\langle name\rangle :]$
The body of the loop ( ) is delimited by DO and ENDDO keywords. A name can be associated with the DO loop. are executed as many times as required. As it stands the loop will cycle indefinitely; we have to append the loop with the proper mechanism to control the number of iterations.