CGI/Perl Guide | Learning Center | Forums | Advertise | Login
Site Search: in

  Main Index MAIN
INDEX
Search Posts SEARCH
POSTS
Who's Online WHO'S
ONLINE
Log in LOG
IN

Home: Perl Programming Help: Regular Expressions:
a regular regular expression ...

 



yaniv_av
Novice

Nov 7, 2002, 11:31 PM

Post #1 of 2 (4151 views)
     a regular regular expression ...  

suppose I have the string:
"a=13 ytr hg a=15 bry dga=19gg a=998 p"
I want to get all the occurences of the numbers that containned in the pattern /a=.* / (into an array)
But I want only the numbers and that's all (gready selection)
In this case I want to get as the result an array that contain:
@result=(13,15,998)
How can I do that ?


Paul
Enthusiast

Nov 8, 2002, 4:09 AM

Post #2 of 2 (4149 views)
     Re: [yaniv_av] a regular regular expression ... [In reply to]  

Please don't post duplicate questions. I answered your original thread and you should have been able to work out the change needed for your follow up question simply with common sense or by reading the regex tutorials found on the web or at perldoc.com

 
 


Search for (options) Powered by Gossamer Forum v.1.2.0

Web Applications & Managed Hosting Powered by Gossamer Threads
Visit our Mailing List Archives