Recent changes Random page
GAMING
Technology
 
Gaming
Entertainment
Science Fiction
Biggest wikis
Hobbies
Music
See more...

While loop

From Programmer's Wiki

Jump to: navigation, search
 

While Loops are the most general type of loop. The argument for a while loop can be any boolean expression. The contents of the while loop will continue to execute as long as the expression is true. Infinite Loops occur when the conditional never evaluates to false.

For more information see the wikipedia article.


[edit] C-like languages

int x = 0;
int y = 10;

  while(x < y){
    x++;
  }


[edit] Language: Pascal

while (x < y) do
begin
   {Do something.}
end;


[edit] See Also

Rate this article:
Share this article: