Archive of posts on May 7, 2023
Labeled
break
,next
, andredo
in RubyMany languages support breaking out of nested loops, such as Perl, Java, JavaScript, C#, etc. Languages that have
goto
can also do this easily. However, in most other languages, it is not easy to break out of nested loops. I want to introduce a way to do this in Ruby.- Categories: programming
- Tags: meta programming, ruby