Comment on Real quick question about the "break"

<- View Parent
RustySharp@programming.dev ⁨11⁩ ⁨months⁩ ago

break and continue are just goto in disguise … use return instead of break

An if statement is goto in disguise. So is a return.

Some would argue having 10x 4-line functions are worse for readability and debugging than a single 40-liner, because to actually understand the code you have to jump around all over the page (another disguised goto - for your eyes!)

source
Sort:hotnewtop