This code came from my desire to use perl for something besides CGI, which is my current perl-y focus. I expected slightly different behavior from File::Find::file, though this may be my Win background shining through. Put simply, this will traverse a filesystem, and determine the # of files based on extention. Again, this was more to keep the programming muscles limber; I plan on using this as a shell for more complex things. I do appreciate any comments you have, however. #use warnings; use strict; use File::Find; my %hash; my @temp; File::Find::find (\&wanted,"c:\\"); my @keys = keys (%hash); @keys = sort_by_value (\%hash); print "-"x20,"\n"; foreach my $key(@keys) {if ($key =~ /^$/) {print "no ext\t:\t"}else{ print "$key\t:\t"}; print $hash{$key},"\n"} sub sort_by_value { my %hash = %{shift()}; sort {$hash {$a} <=> $hash{$b} } keys %hash; } sub wanted { my @file ; my $fname; # don't attempt to read a directory. if (-d $_) {return}; $fname = $File::Find::name; # turn any '/' into a '\' # then make sure that any '\\' get turned into '\' $fname =~ s#\/#\\#g; $fname =~ s#\\\\#\\#; @temp= split /\./, $_; # mmm. autovivification $hash{@temp[1]}++ }