good chemistry is complicated, and a little bit messy -LW |
|
PerlMonks |
comment on |
( [id://3333]=superdoc: print w/replies, xml ) | Need Help?? |
Like everything in Perl, the ternary is ripe for abuse if you want to abuse it. I used to work with a guy who wrote stuff like this:
Yes, that's a real-life example, in production code, for a multi-million dollar corporation, although I cleaned it up a bit. Personally, I like the ternary, as long as you don't go nuts with it. I only use it in assignments, and I don't nest them. In reply to Re: Ternary operators: a hinderance, not a help
by friedo
|
|