Syntactic Confectionery Delight | |
PerlMonks |
unless statementsby root (Monk) |
on Nov 05, 1999 at 04:10 UTC ( [id://947]=perltutorial: print w/replies, xml ) | Need Help?? |
Unless statements allow you to say unless something is true do this.
For example: $value=20; unless($divisor==0){ #so long as the $divisor isn't equal to 0 $value=$value/$divisor; #go ahead and divide $value by $divisor } else { $divisor=1; #otherwise set $divisor to 1 }If you've got that I suggest you take a look at while loops
Back to
Tutorials
|
|