in reply to Re: newbie regex question: substituting repeating occurences for different replacements
in thread newbie regex question: substituting repeating occurences for different replacements
while(<DATA>) { my $i; chomp; print join('', map { $i++; "<col$i>$_</col$i>" }, split /;/)."\n"; } __ hello;this;is;a;test this;is;another;simple;test
Makeshifts last the longest.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re^2: newbie regex question: substituting repeating occurences for different replacements
by eric256 (Parson) on Jul 23, 2003 at 17:56 UTC | |
by Aristotle (Chancellor) on Jul 23, 2003 at 19:05 UTC |