Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW

Re: Question on Regex

by karlgoethebier (Parson)
on Nov 18, 2012 at 14:00 UTC ( #1004415=note: print w/ replies, xml ) Need Help??

in reply to Question on Regex

Hello, perhaps this helps.

#!/usr/bin/perl use strict; use warnings; my $string = qq ( +ind/?APath=; $string =~ m/.+\/.+\/.+\/(.+)\/.+/; print $1;

Update: I did not count right, sorry...

$string =~m/.+\/.+\/.+\/.+\/(.+)\/.+/;

Regards, Karl

«The Crux of the Biscuit is the Apostrophe»

Comment on Re: Question on Regex
Select or Download Code
Replies are listed 'Best First'.
Re^2: Question on Regex
by Anonymous Monk on Nov 18, 2012 at 14:29 UTC

    Thanks Karl, Got it... :)

      Yes, i know that i tend to sink before i type. But i'm working hard to get better ;-) Regards, Karl

      «The Crux of the Biscuit is the Apostrophe»

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1004415]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others rifling through the Monastery: (3)
As of 2015-11-26 19:43 GMT
Find Nodes?
    Voting Booth?

    What would be the most significant thing to happen if a rope (or wire) tied the Earth and the Moon together?

    Results (706 votes), past polls