From: "David A. Black" Date: 2009-09-26T00:29:23+09:00 Subject: Re: Roulette & rand Hi -- On Fri, 25 Sep 2009, Aldric Giacomoni wrote: > Symbols are a good habit to get into because they always represent a > unique object, the symbol, while strings always create a new object. That's true, but your example: > irb(main):009:0> 0.object_id > => 1 > irb(main):010:0> 0.object_id > => 1 > irb(main):011:0> "0".object_id > => 21396750 > irb(main):012:0> "0".object_id > => 21393440 doesn't demonstrate it; you don't have any symbols :-) irb(main):001:0> :x.object_id => 158738 irb(main):002:0> :x.object_id => 158738 David -- David A. Black, Director Ruby Power and Light, LLC (http://www.rubypal.com) Ruby/Rails training, consulting, mentoring, code review Book: The Well-Grounded Rubyist (http://www.manning.com/black2)