--- Chris Reay <mrchameleon / hotmail.com> wrote: > How do I refer to my objects' keys in a Hash? The > following snippet > demonstrates my problem ... > > Thanks > > Chris > > ------------------------------------------------------------------ > class Company > def initialize(name) > @name = name > end > > def to_s > sprintf("Company(%s)", @name) > end > > def hash > @name > end > end > What are you trying to accomplish with the "hash" method here? Your example works if you don't "def hash". __________________________________________________ Do You Yahoo!? Make international calls for as low as $.04/minute with Yahoo! Messenger http://phonecard.yahoo.com/