The PHP while() loop
Sat, 28 January, 2006 – 11:54 pm
The simplest loop is the while loop. Simple format and repeats while the condition is true.
[source:php]$num = 0;
while ($num < 10) {
print $num;
$num++;
}
[/source]
This of course would print the numbers from 0 to 9 in one long line ie. 0123456789


No Responses to “The PHP while() loop”