Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
The basic idea is that 123 is replaced by what function returns. Obviously the operation it represents could be easily done via s/ but this is just the example instead of what I am actually trying to do with &functionmy $foo = 'bar 123 moo cow'; $foo = s/(123)/function($1)/; sub function { my $argument = shift; $argument = "rab"; return $argument; }
|
|---|