![]() |
|
Perl: the Markov chain saw | |
PerlMonks |
Re: Perl style question: loops with postconditionby hsmyers (Canon) |
on Jun 28, 2002 at 20:04 UTC ( [id://178123]=note: print w/replies, xml ) | Need Help?? |
I'd go with do { } while($condition); since the other two violate some of my own pet peeves. I don't like invariants in place of conditions-- too easy for me to miss let alone the poor fool who is maintaining my code. If I need a GOTO fix, I'll code in assembler. Besides the first construct has fewer semantic elements to screw up! –hsm "Never try to teach a pig to sing…it wastes your time and it annoys the pig."
In Section
Seekers of Perl Wisdom
|
|