Manasi Bopardikar wrote:
Does anyone know how do I remove the beginning and the trailing * from
*****STAFF*****

my $stuff = '*****STAFF*****';

s/^\*+//, s/\*+$// for $stuff;


Or if you want to remove all * regardless of where in the string they are located:

$stuff =~ tr/*//d;



John
--
Perl isn't a toolbox, but a small machine shop where you
can special-order certain sorts of tools at low cost and
in short order.                            -- Larry Wall

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/


Reply via email to