From: 7stud -- Date: 2008-03-04T22:22:00+09:00 Subject: Re: and statement Subbu wrote: > Thank you so much. I looked up 'and' && operands in the PickAxe book > and this is what it says: > "The 'and' and && operators evaluate their first operand. If false, > the expression returns the value of the first operand; otherwise, the > expression returns the value of the second operand" > Which doesn't appear to be true. Look at this: result = (x=20) puts result #20 result = true and x=20 puts result #true The output isn't the same. -- Posted via http://www.ruby-forum.com/.