You can use in the following way:

$exec = "ls -l";
$src  = system($exec);

-----Original Message-----
From: gohaku [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, July 06, 2004 9:59 AM
To: Perl Beginners
Subject: Backticks alternative?

Hi everyone,
After using backticks to retrieve executable output,
I would like to know if there is a backtick alternative.

For example, to get a File Listing on a Unix-based system,
I will do the usual:

$exec = "ls -l";
$src = `$exec`;

Unfortunately, I find the ` to be unreadable and confusing
because it looks like a quote.

Thanks in advance.
-gohaku


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>



--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>


Reply via email to