From: tored@... (Tore Darell) Date: 2003-05-31T08:53:55+09:00 Subject: Re: exiting of a block Emmanuel Touzery wrote in message news:<200305260838.02882.emmanuel.touzery@wanadoo.fr>... > Hello, > > it's a newbie question... > i wanted to do something like: > > result1 = [1, 2, 3].find { |e| > if e == 2 > return true > else > return false > end > } > (with several if/else one in each other rather than one big condition, for > code readability) Can't you just do: [1, 2, 3].find{|e| if e == 2 true else false end } ? You can nest several if-else-blocks inside if you want, with each block returning the last statement.. I think I understood your problem, but ignore me if this is not what you're seeking :)