in reply to addition in regular expressions

Or use one of the tricks to interpret an expression into a double-quoted string (which the right side of s/// is like):
s!total of (.*?) and (.*?)\n!total is @{[$1+$2]}\n!g

Replies are listed 'Best First'.
Re^2: addition in regular expressions
by texuser74 (Monk) on Dec 13, 2007 at 09:38 UTC
    hi thanks, your solution did the magic for me.