|
|
for Loops
for Loops
| To decrement, you use $variable_name--. To
increment, you use $variable_name++. |
- Executing the statement block, the script would then print
out the number nine. Then, it would go back through the
loop again and again, printing each decremented numbers
until $number was less than zero. At that point, the test
would fail and the for loop would exit.
Additional Resources:
while
Table of Contents
Using logical operators (&& and ||)
|
|