You realize @array has only one element, the long single-quoted string?
Perhaps this:
use strict; my @array=('GAP_SPAN09 - GAP SPAN base (Scratch Testing [TSMC11] : tsm +c11 +_wld(sxfatd12j)) GAP_SPAN03 - GAP SPAN base (DFD E2E Testing [TSPAN04 +] : tspan04-dfdint-wld(sxfamd6f)) POS_WLI02 - POS_WLI02 Web Logic Int +egrator'); my @newarray = $array[0] =~ /(\S+) - /g; print "$_\n" for @newarray;
In reply to Re: regex assistance
by hbm
in thread regex assistance
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |