in reply to Re^2: Concatenation to elements in an array !
in thread Concatenation to elements in an array !
You can't do something repeatedly without some loop.
That doesn't mean that all loops are equal, though. You might be able to use something like
$line =~ s/(?:\t|\z)\K/a/g; # Requires 5.10+ $line =~ s/(\t|\z)/${1}a/g; # Slower, but works with earlier versions
Update: Accidentally said "with some loop." Fixed.
|
|---|