print "Enter starting file name: "; $start = <>; print "Ending file name: "; $end = <>; chomp($start); chomp($end); opendir(MDSDIR,"/mds/nvision1"); while ( $file = readdir(MDSDIR) ) { if ($file =~ /000[0-9A-C]*\./) { $temp = $&; chop($temp); if ( $temp ge $start && $temp le $end ){ $temp = "/mds/nvision1/" . $temp . ".$'"; print "unlinking $temp\n"; unlink($temp); } } } closedir(MDSDIR);