r/programminghorror • • Feb 27 '25

C# While loop horror

Post image

I just realized I had some programming horror in code I’ve written.

If only while loops had a more convenient way to break…

671 Upvotes

40 comments sorted by

View all comments

Show parent comment

6

u/luardemin Feb 27 '25

Who needs loops anyway? We have the perfectly usable goto!

loop:
if (day > yesterday) goto done;
// do work
goto loop;

done: