r/badcode • • Feb 06 '23

c# How not to handle exceptions in c#

Post image
1.0k Upvotes

r/badcode • • Sep 03 '20

php fair enough ...

Post image
1.0k Upvotes

r/badcode • • Dec 09 '20

c Silly isEven function I wrote a couple of years ago as a meme after noticing npm had modules for this

Post image
1.0k Upvotes

r/badcode • • Jun 23 '20

java 'val' is a boolean value.

Post image
1.0k Upvotes

r/badcode • • Jan 30 '21

python Why use strip, when this does the trick?

Post image
998 Upvotes

r/badcode • • Aug 27 '21

python Wrote this code forgetting that if statements exist

Post image
992 Upvotes

r/badcode • • Oct 02 '22

python I was searching for password generator. I found this...

Post image
990 Upvotes

r/badcode • • Jul 30 '21

js 😏

Post image
988 Upvotes

r/badcode • • May 07 '21

js worst bad code i've seen. 160 lines to generate a random coordinate in a 128x128 square that is separated by a period (ie. XXX.XXX)

Post image
986 Upvotes

r/badcode • • Nov 10 '20

c++ My teacher's code formatting

Post image
983 Upvotes

r/badcode • • Feb 06 '21

c I am not proud of what I have done. It goes like that until line 2300

Post image
981 Upvotes

r/badcode • • Sep 29 '21

c# Behold, the ultimate (and literal) toggling switch. I guess booleans are overrated.

Post image
980 Upvotes

r/badcode • • Jul 17 '20

js Found this "answer" on Stackoverflow. Pretty sure it's not working.

Post image
978 Upvotes

r/badcode • • Apr 14 '22

typescript I wish people were taught basic logic before programming

Post image
977 Upvotes

r/badcode • • Jan 29 '21

java Young me did not understand static variables. Or classes. Or really much else

Post image
975 Upvotes

r/badcode • • Feb 03 '21

js The future of Mexico depends on a Jquery of 1500 lines.

Post image
973 Upvotes

r/badcode • • May 03 '23

c Solve the problem without using a loop

Post image
964 Upvotes

r/badcode • • Oct 11 '20

c# (OC) This is for a tic tac toe game i made, smol brain go brr

Post image
962 Upvotes

r/badcode • • Apr 22 '21

js ternary operators at their maximum potential

Post image
960 Upvotes

r/badcode • • Mar 07 '21

c++ So this is the source code of the official solution of a problem from the National Olympiad

Post image
959 Upvotes

r/badcode • • Aug 10 '20

c Found on a tutorial website, please do not comment your code on the same line

Post image
958 Upvotes

r/badcode • • Jun 08 '21

js haha ternary go brrrrrr

Post image
957 Upvotes

r/badcode • • Nov 03 '20

other language Assembly is hard...

Post image
957 Upvotes

r/badcode • • May 28 '21

lua From a free model on Roblox... continues for 200 lines

Post image
956 Upvotes