in reply to Re: taking an output in a variable
in thread taking an output in a variable

If you want to know how to pass strings that look like variable names to the shell via backticks, you need to quote the special chars:
my $res = `echo \$JAVA_HOME`;
To be completely thorough and pedantic, you can also use the qx operator with single quotes:
my $res = qx'echo $JAVA_HOME';

-QM
--
Quantum Mechanics: The dreams stuff is made of