#!/usr/bin/env perl use strict; use warnings; use Test::More tests => 1; my $name = "greenfield (Glossary) (100)"; my $want = '100'; $name =~ /([^(]+)\)$/; is ($1, $want, "Matched");
If you want what's at the end, anchor it to the end.
In reply to Re^5: XML data extraction
by hippo
in thread XML data extraction
by snehit.ar
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |