C:\> test.pl Argument "0x2" isn't numeric in addition (+) at C:\test.pl line 9. Argument "0x28" isn't numeric in addition (+) at C:\test.pl line 9. 0 0 #### my $this = sprintf("0x%x", 40); my $that = sprintf("0x%x", 2); my $other = eval "$this + $that"; printf "$other %x\n", $other;