How to copy a file in perl?
Answer / Sahil Chaudhary
In Perl, you can use the 'sysopen' and 'sysread/syswrite' functions to read from one file and write to another. The syntax is: sysopen(my $out_file, $output_filename, O_WRONLY | O_CREAT); while (sysread($in_file, my $line, 4096)) { syswrite($out_file, $line) } close($in_file), close($out_file).
| Is This Answer Correct ? | 0 Yes | 0 No |
how to connect cisco switch uisng perl script
What are the steps involved in configuring a server using cgi programming?
How will you access an element of a perl array?
What are stdin, stdout and stderr?
Why we use CGI?
Differentiate between c++ and perl.
Why do you use Perl?
What is the main function of cookie server?
How can we create perl programs in unix, windows nt, macintosh and os/2 ?
What is the difference between for & foreach, exec & system?
Does Perl have reference type?
What is “grep” function in perl?