use strict; my $x = 3; my $y = "2 * $x"; # interpolation here sets y to '2 * 3' already! my $z = eval $y; # $z is 6 now print "\$x is $x"; print "\$y is $y"; print "\$z is $z";