in reply to Working of split

Perl split will suppress trailing empties unless you give it the third argument. Does this do what you want?

$_ = "val\t\t\t"; my @a = split /\t/, $_, 4; print scalar( @a), $/;

After Compline,
Zaxo