while expression statement group endWhat it does is evaluate expression first. If its logic value is true, the statement group is executed. Then expression is evaluated again, and if it is true statement group is executed again. This is repeated over and over until the value of expression becomes false. For example:
s=0; k=1; while k <= 100 s += k++; endThe execution of the loop commands should be able to affect the value of the expression, so that the loop comes to an end at some point. Otherwise, it will run forever, and the interpreter will have to be closed by the operating system.