aj.kohler has asked for the wisdom of the Perl Monks concerning the following question:
I am reading in a directory of filenames:
12345_-v1.pdf
12345_Av1.pdf
123456_-v1.pdf
123456_Av1.pdf
123456_Bv1.pdf
etc...
I need to pattern match the root filename(12345), and display the latest version of file(-v1,Av1,B1):
12345_Av1.pdf
123456_Bv1.pdf
How can I accomplish this? I am not too experienced in RE's at this time.
Thanks
AJ
updated format
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Pattern Matching in Arrays
by przemo (Scribe) on May 11, 2009 at 16:23 UTC | |
Re: Pattern Matching in Arrays
by ciderpunx (Vicar) on May 11, 2009 at 16:30 UTC | |
by aj.kohler (Initiate) on May 12, 2009 at 13:49 UTC | |
by przemo (Scribe) on May 12, 2009 at 17:59 UTC | |
by aj.kohler (Initiate) on May 12, 2009 at 20:09 UTC | |
by przemo (Scribe) on May 12, 2009 at 22:44 UTC | |
| |
by ciderpunx (Vicar) on May 13, 2009 at 17:01 UTC |
Back to
Seekers of Perl Wisdom