From: m94asr@... Date: 2006-09-08T06:55:12+09:00 Subject: Faster datastructure for lookups wanted Hi all, maybe somebody can recommend me the right datastructure or any other advice would be a big help. My code spends most of its execution time doing lookups from a hashtable with about 1M keys. The keys are strings and the values are arrays of integers. Most of the time only of length 1. I do not care how long the construction of the datastructure takes, but the lookup should be as fast as possible. xs.each{|x| if found = hash[x] #do sth. end } Thanks a lot! -Armin