in reply to spliting arrays
my @id = split /-|\s/, $ident;
The above code would solve the problem illustrated in the text of your question. Notice: I used \s to indicate "space". \s is not strictly synonomous with "space", as it also matches tab, newline, etc. You could use the actual space character in your split regex. I used \s to make it easy to read the regex.
The subject of your question, "Splitting Arrays" doesn't match the text of your question. Is there something you left out? We're not splitting arrays here, we're splitting strings into an array.
Dave
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
| A reply falls below the community's threshold of quality. You may see it by logging in. |