jrsmith has asked for the wisdom of the Perl Monks concerning the following question:
is it bad form to leave off the else in if statements if you are not going to use it? just something i'm pondering..
like this-
like this-
instead of-if ($x = $y) { print "$y = $x\n"; }
if ($x = $y) { print "$y = $x\n"; } else { #waste of space }
|
---|
Replies are listed 'Best First'. | |
---|---|
RE: a question on style
by Ovid (Cardinal) on Jun 12, 2000 at 20:30 UTC | |
by jrsmith (Pilgrim) on Jun 12, 2000 at 20:36 UTC | |
by Ovid (Cardinal) on Jun 12, 2000 at 20:43 UTC | |
by jcwren (Prior) on Jun 12, 2000 at 20:52 UTC | |
by jrsmith (Pilgrim) on Jun 12, 2000 at 21:35 UTC | |
Re: a question on style
by lhoward (Vicar) on Jun 12, 2000 at 18:41 UTC | |
RE: a question on style
by nuance (Hermit) on Jun 12, 2000 at 18:43 UTC | |
Re: a question on style
by cleen (Pilgrim) on Jun 13, 2000 at 04:00 UTC |
Back to
Seekers of Perl Wisdom