目录下只有一个文件:
[laps0@localhost ~]$ ls -a data/rawdata/profile/from_liju/hd
. .. 20100701.TXT
代码如下:
#!/usr/bin/perl
my $path="/home/laps0/data/rawdata/profile/from_liju/hd";
opendir(DIR,$path) or die " Error : can't open $path :$!";
my $file;
while ($file=readdir DIR)
{
print "the file is : $file \n";
open(FILE,"$file");
my @var =