From: basi Date: 2005-04-28T11:19:29+09:00 Subject: Hash as Checklist Hello, I need to check if a word is in a list. I'm using hash because the lists can be long (i'm under the impression hash is faster than array). Basically I'm only interested that a key exists. I have to create entries like: h = { "one" => true, "two" => true, "three" => true, "four" => true, "five" => true } So h["one"] gives true, and h["seven"] returns nil. But typing the dummy value "true" is a waste of effort, and there's an ugliness in there. Is there a better way to design a simple checklist? Thank you for your help basi