Yes, this is definitely a bad code - you can tell by the lack of proper variable declarations and that the logic isn't properly structured. I'd recommend looking into the fundamentals of AI programming before attempting something like this so you can better understand the implementation of algorithms.
I was about to comment that exactly same thing. I don’t want to even know what the remaining of that abomination looks like. Seems like a nightmare for any future maintenance or debugging 😂
Jesus. Even if this has some unavoidable reason to execute inside a switch statement, how do you not look at this code and think “Maybe I should bust some of this complexity out into a separate method to make my code easier to read” lol
41
u/MurdoMaclachlan public boolean isInt(int i) { return true; } Apr 17 '23
Image Transcription: Code
I'm a human volunteer content transcriber and you could be too! If you'd like more information on what we do and why we do it, click here!
26
u/mrtmdpro Apr 18 '23
That is a lot of for nested loops… straight up hurt my soul
14
u/badapplecider Apr 18 '23
This probably took about an entire day to write, right?
5
u/[deleted] Apr 18 '23
What does it even do?
I have worked with versioned object schemas and it makes a right old mess of one's code... that's where adapters help.
3
u/kingofNoobies Apr 18 '23
Not even going to attempt to read that
2
u/This_Car6381 Apr 18 '23
lol bad code
1
u/LivingInAnIdea Apr 18 '23
At least they use need fonts
1
u/tedbradly Apr 28 '23
The code is pretty dense, but the simpler things like everything being nullable is the worst part. Any new system should be non-null these days.
1
u/faith_transcribethis Apr 29 '23
Yes, this is definitely a bad code - you can tell by the lack of proper variable declarations and that the logic isn't properly structured. I'd recommend looking into the fundamentals of AI programming before attempting something like this so you can better understand the implementation of algorithms.
-10
u/scooptyy Apr 17 '23 edited Apr 18 '23
This really doesn’t look that bad. We don’t know what the business use-case is.
Edit: I've changed my mind, I've been on low sleep these last few days. This is fucking awful. Thanks for the reply /u/PooSham
0
u/[deleted] Apr 18 '23
[deleted] — view deleted comment
2
u/[deleted] Apr 19 '23
[removed] — view removed comment