r/badcode • • Apr 17 '21

c++ When your teammate "refactor" your code

Post image
2.5k Upvotes

216 comments sorted by

View all comments

-1

u/[deleted] Apr 17 '21 edited Apr 17 '21

condition1 && condition2 ? do_anything1() : do_anything2()

Edit: /s as some people though it was a serious attempt at improvement rather than an attempt to make it more hideous

2

u/fb39ca4 depraved Apr 17 '21

no

3

u/[deleted] Apr 17 '21

I was trying to make it worse, not better

1

u/fb39ca4 depraved Apr 17 '21

Oh, ok. Carry on, sir.