From: "Alexandru E. Ungur" Date: 2006-02-27T18:24:11+09:00 Subject: Re: Ruby Whitespace Semantics >>> sender: "Almann Goo" date: "Mon, Feb 27, 2006 at 04:43:35PM +0900" << Can someone please explain the semantics behind the following: > > irb(main):001:0> a = ( 4 + 5 ) > => 9 > irb(main):002:0> a = ( 4 > irb(main):003:1> + 5 ) > => 5 > irb(main):004:0> a = ( 4 + > irb(main):005:1* 5 ) > => 9 > > The first and last statements make sense to me, but why is the second one > returning 5? > > I find semantics like this troubling, and no documentation sheds light as > to what would cause this behavior. This behaviour is documented, at least here: http://www.rubycentral.com/book/language.html and probably in other placess too (but I wouldn't know about them as I am learning Ruby for just a little more than 1 week). Hope it helps, Alex