Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re: replace a string multiple times

by igelkott (Priest)
on Nov 16, 2014 at 09:58 UTC ( [id://1107337] : note . print w/replies, xml ) Need Help??


in reply to replace a string multiple times

You wrote "string" in the title and your question includes a quoted string but still, asking for "int" makes me wonder if you really meant that you're looking for integers. Seems unlikely, but here's a solution, just in case:

s/(\d+)/$1 $1 $1/g;