M626
Programmer
- Mar 13, 2002
- 299
Hi,
I am looking to do the following in perl. I know how to do it in vb but need it in perl.
I need a script to open a text file with test that contain file names, one per line. Once it opens the file, i need to remove the carage return and separate the file names by a space. Also, i need to have the script look at a directory and output the file names to a file is the same format ( one long string separated by a space.)
Example:
In:
test1
test2
test3
out:
test1 test2 test3
I am looking to do the following in perl. I know how to do it in vb but need it in perl.
I need a script to open a text file with test that contain file names, one per line. Once it opens the file, i need to remove the carage return and separate the file names by a space. Also, i need to have the script look at a directory and output the file names to a file is the same format ( one long string separated by a space.)
Example:
In:
test1
test2
test3
out:
test1 test2 test3