Fuzion Logo
flang.dev — The Fuzion Language Portal
JavaScript seems to be disabled. Functionality is limited.

Idiom # 43: Break outer loop

See programming-idioms.org:

Code

There is no break or goto in Funsion, so we have to help ourselves differenty. In Fuzion, a loop that may execute successfully (until condition become true) or not (until the iterated set is exhausted) can be used as a boolean expression. Its value is true on success. Consequently, we can use the complete inner loop as the until condition of the outer loop:







Running Example