develooper Front page | perl.beginners | Postings from September 2011

double substitution

Thread Next
From:
Rajeev Prasad
Date:
September 19, 2011 17:57
Subject:
double substitution
Message ID:
1316480214.45699.YahooMailNeo@web114214.mail.gq1.yahoo.com
$string="alpha number='42'"
$string=~s/.*\=// ;
$string=~s/\'//g;

to get 42 and not '42'


can these two substitutions be combined?

thank you.


Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About