r/badcode • • Apr 24 '21

python very efficient and scalable code

Post image
1.0k Upvotes

110 comments sorted by

View all comments

281

u/BR34D_ Apr 24 '21

This Code is screaming REFACTOR ME!

135

u/sanglesort Apr 24 '21 edited Apr 25 '21

this could be one function, like just have a tag param

edit: I am sorry for being obvious, I beg for mercy

15

u/BaconKami Apr 25 '21

And then all the functions could call that 'chosetagGeneric' method, and if you want to add a new tag you just add the function that calls it right? (I am joking of course)

5

u/5p4n911 Apr 25 '21

Honestly, I might make some stupid shorthand functions for it in some obscure place just because I am lazy to write those extra ""s