in reply to Split function
If you can't have it die, you can make it do that if split splits into only one part.
or, alternatively, you can do(my ($s, $a, $c, $r) = split /[,\t]/) == 1 and die;
edit code fixed, thanks ColonelPanicdie if not defined $a;
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^2: Split function
by ColonelPanic (Friar) on Dec 03, 2012 at 13:42 UTC |
In Section
Seekers of Perl Wisdom