in reply to Possible to use "split", but save the delimiter?
If the PATTERN contains parentheses, additional list elements are created from each matching substring in the delimiter.produces the list value1. split(/([,-])/, "1-10,20", 3);1. (1, '-', 10, ',', 20)
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Possible to use "split", but save the delimiter?
by ultranerds (Hermit) on Feb 08, 2010 at 15:11 UTC | |
|
Re^2: Possible to use "split", but save the delimiter?
by ultranerds (Hermit) on Feb 10, 2010 at 16:50 UTC | |
by BrowserUk (Patriarch) on Feb 10, 2010 at 17:02 UTC | |
by ultranerds (Hermit) on Feb 10, 2010 at 17:38 UTC |