73
Why use if/else when you can use try/if/catch?
(lemmy.world)
Why use goto when you can throw exceptions to escape nested for loops?
exceptions are just fancy gotos
Exceptions are fancy returns. Everything else is fancy goto, including returns...
I don’t see a catch
in the screenshot. Maybe this block just has a finally
that cleans some things up before the exception is thrown?
Why use try/if/catch when you can use try/if/switch/catch?
Why throwing an exception without a message, when you can use 0/0
Post funny things about programming here! (Or just rant about your favourite programming language.)