Is there an easier way to grab only one element out of a match other than doing the followng:
my $date = ($xml_file =~ m/(\d+)-sys_char/)[0];
# or
my $date = $1 if $xml_file =~ /(\d+)-sys_char/;
Is there a flag to specify that m doesn't return an array but just one concatenated value of all the $# matches, so I can do:?
my $date = ($xml_file =~ mSOMEOPT/(\d+)-sys_char/);
removing the 0 from the end?