Hi,
I have more than 1 files in the directory. In bash, I can use
cd /work
for x in `ls`
do
:
:
done
to run for each file in the directory.
How about in perl script?
filepath="ABC1"
open(FILE, $filepath) or die "$filepath cannot be opened.";
while(<FILE>) {
:
:
}
close(<file>)
because the open command just open the file ABC1 only. If I have ABC2, ABC3,ABC4 and ABC5 files.... how to let perl script also can run for the other files?
Thanks for you advise.