From: Stanislav Karchebny Date: 2003-09-09T17:31:45+09:00 Subject: Re: Hash-ish and Arrays and Duplicates > Currently I have a hash, which key is the fully qualified > pathname/file and its value is the md5sum (by the way: Is there a > md5sum-generator inside Ruby ?) of that file. Key = md5sum, values = array of filenames (feed with "hash[md5(filecontents)] << filename") this way you know the duplicates names and can find if they are duplicated by doing something like hash.each { |x| puts "dups" if x.size > 1 } It may be not quite as fast esp. if there are no duplicates, but should work. -- keep in touch. berkus. -- http://lye.upnet.ru/