in reply to How to replace the cut command from cshell in Perl
File::Basename is the best way to go, but sometimes if I'm feeling particularly obtuse, I might use something like:</>
my $file = (split(/\//, $path))[-1];
I don't recommend it tho :)
--
"Perl makes the fun jobs fun
and the boring jobs bearable" - me
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: How to replace the cut command from cshell in Perl
by a (Friar) on Jan 20, 2001 at 10:33 UTC |