>> how can I output "first line\n" and "last line\n" to the screen
   >> but save the result of system command "ls" to a file(eg
   >> "result")(not appear on the screen")?

>> On 24 Nov 2002 23:42:50, Jeff 'japhy' Pinyan <[EMAIL PROTECTED]> said:
   > Unbuffer STDOUT:
   >   $| = 1;
   > See 'perldoc perlvar' for information about the $| variable.

This doesn't help with storing the output from ls to a file rather than
STDOUT, which should be done with something like:

   open(FILE, ">result") or die "$!";
   print FILE `ls`;
   close FILE;

- Chris.
-- 
$a="printf.net";  Chris Ball | chris@void.$a | www.$a | finger: chris@$a


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to