From: Chris Alfeld Date: 2006-03-31T03:53:52+09:00 Subject: Re: How to break out deeply nested loops? (newbie) Not nicely. This is discussed in the Pickaxe. For example catch "BreakOuterLoop" do for i in 1..10 print "out #{i}\n" for j in 1..10 print "in #{j}\n" throw "BreakOuterLoop" if i+j > 16 end end end On 3/30/06, Talha Oktay wrote: > I sometimes need to break out, next or redo deeply nested loops in different > levels instead of the innermost enclosing scope. Is there a facility to > label blocks or loops and redo, next or break to the labeled blocks or > loops as in some other programming languages? > > Thanks in advance. > >