--20cf30549edf3cf7b20496ee8999 Content-Type: text/plain; charset=ISO-8859-1 That sounds about right. Readability. On Wed, Dec 8, 2010 at 11:55, Ilya B. <ilyabe / gmail.com> wrote: > Question about this method in Ruby Koans -> about_hashes.rb > > def test_changing_hashes > hash :one "uno", :two "dos" } > hash[:one] eins" > > expected :one "eins", :two "dos" } > assert_equal true, expected hash > > # Bonus Question: Why was "expected" broken out into a variable > # rather than used as a literal? > end > > Referring to the bonus question, is there any reason other than that > it's more readable this way? Seems to accomplish the same thing? > > -- > Posted via http://www.ruby-forum.com/. > > --20cf30549edf3cf7b20496ee8999--