Why is the below code is not working?

`-d` and `-f` are not functioning on my Windows machine.

```
use strict;
use warnings;

use Data::Dump qw/pp/;

my $path="C:/perl/workspace";
opendir ( DIR, $path ) || die "Error in opening dir $path\n";

my (@file,@dir);

while (my $filename=readdir(DIR)) {
    next if ($filename =~ m/^\./);
    if (-f $filename) {
        push(@file,$filename);
    } elsif (-d $filename){
        push(@dir,$filename);
    }
}

#pp \@file,\@dir;
print "@dir";

```