opendir DIR, $dir or die $!; read DIR for 0 .. 1; my $files = scalar readdir DIR; closedir DIR; $files == 0 && print "Verzeichnis leer!";