Zombie has asked for the wisdom of the Perl Monks concerning the following question:
This code is tiresome to write, and difficult to read too. How do I write codes to test multiple conditions more conveniently?if ($value1 == 30) { if ($value2 > 0 ) { if ($string1 eq "winner" ) { print ("You are a WINNER!\n"); } } }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Logical Operators
by merlyn (Sage) on May 23, 2001 at 20:38 UTC | |
by Zombie (Acolyte) on May 23, 2001 at 21:08 UTC | |
by merlyn (Sage) on May 23, 2001 at 21:19 UTC | |
by AidanLee (Chaplain) on May 23, 2001 at 21:54 UTC | |
|
Re: Logical Operators
by princepawn (Parson) on May 23, 2001 at 21:51 UTC | |
by Zombie (Acolyte) on May 24, 2001 at 20:45 UTC | |
by myocom (Deacon) on May 26, 2001 at 10:19 UTC |