I want to use a substitution regular expression to split words that are separated by commas onto separate lines. Say for example I wanted to split these words as follows -
Donna, 24 years of age, born Ipswich at 8.00pm,
24 years of age,
born Ipswich at 8.00pm,
The first bit of code will read
my $text = $ARGV
$text =~ s/[a-z],\n/i;
print $text. "/n";
I am trying to replace text with commas and put them into a list like above.
Can anyone help me with this script or suggest any better ideas?