in reply to Is it possible to use a scalar to call a subroutine?

You're almost there, if you turned warnings on you would have seen that the interpreter thought you wanted to print to a filehandle. a tiny modification would've achieved what you're looking for, note the infix arrow operator in the print line..
use warnings no strict 'refs'; my $sub = 'do_this'; print $sub->("Fred"); sub do_this { my $var = shift; return "My name is $var"; } sub do_that { my $var = shift; return "My name is not $var"; }


Excellence is an Endeavor of Persistence. Chance Favors a Prepared Mind.