C:\TEMP>perl comp_files.pl comp_files.pl is newest in C:/temp/A C:\TEMP>set DEBUG=1 C:\TEMP>perl comp_files.pl %hash = ( 'comp_files.pl' => { 'C:/temp/B' => 1493306489, 'C:/temp/A' => 1493307421 } ); comp_files.pl is newest in C:/temp/A