in reply to
Re: Re: Re: Idiomatic optimizations
in thread Idiomatic optimizations
Puh-lease, use some whitespace! Here are some alternatives:
$i ? $i = 1 : $i = 0;
$i = $i ? 1 : 0;
$i = !!$i || 0;
$foo = $foo ? 1 : 0; # Single-letter variable names:
# easy to type, hard to read
Always pass referances not data structures
Most references are the root of data structures, so I think you meant "Always pass references instead of flattened hashes or lists". Note that you can't use this if the sub in question doesn't expect it.
- Yes, I reinvent wheels.
- Spam: Visit eurotraQ.