in reply to parsing and evaluating a string

Like bobf, I have assumed that + is a concatenation. I thought I'd have a try without using split or map. Here it is

use strict; use warnings; my $str = "char(123)+char(107)+char(112)+char(43)"; my $newStr; () = $str =~ m|(\d+)(?{$newStr .= chr($1)})|g; print "$newStr\n";

When run this produces

{kp*

Cheers,

JohnGG