The while statement is executed repeatedly as long as the value of expression remains nonzero.
The test takes place before each execution of the statement.
while (expression) statement
Example:
void main()
{
int expr = 10;
while (expr)
{
printf("%d",expr);
expr--;
}
}
Output:
10987654321