http://www.perlmonks.org?node_id=99421


in reply to Perl and your environment

& is not the concatenation operator in Perl. What you're looking for is the dot. For this example, there's no need to use it, though. Also, there's no reason to use backticks to get environment variables; they're stored in the %ENV hash.

my $testval = "~$ENV{USER}/foo";