Your last example has the same bug as the OP. It should be;
my $based_on = defined( $ARGV[0] ) ? shift : 'tp'; my $top = defined( $ARGV[0] ) ? shift : 1;
In reply to Re^2: Ternary Operator for Multiple Arguments Passing
by eric256
in thread Ternary Operator for Multiple Arguments Passing
by neversaint
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |