On Tue, Mar 16, 2010 at 11:47 AM, jbl wrote:
> I am reading a directory and creating an array of .png file names. I
> know for a fact that there are 1025 png files in the folder
> With $count = @files I get 1027
> With $last = $#files I get 1026
> $files [0] = .
> $files[1] = ..
> I have heard of
jbl wrote:
I am reading a directory and creating an array of .png file names. I
know for a fact that there are 1025 png files in the folder
With $count = @files I get 1027
With $last = $#files I get 1026
$files [0] = .
$files[1] = ..
"." is the current directory, ".." is the parent directory.
jbl schrieb:
I am reading a directory and creating an array of .png file names. I
know for a fact that there are 1025 png files in the folder
[snip]
my @files = grep !/^\.png/, readdir FILENAMES;
Try it better positive:
my @files = grep /\.png$/, readdir FILENAMES;
;-)
Greetings
Rober
I am reading a directory and creating an array of .png file names. I
know for a fact that there are 1025 png files in the folder
With $count = @files I get 1027
With $last = $#files I get 1026
$files [0] = .
$files[1] = ..
I have heard of being one off by not taking into account the
difference in n