It's worth noting that there's something else going on here.
AI code looks readable. It looks logical. Enough that any single function is plain enough, so long as the called functions do what they appear to describe.
But it does not follow any one strand of logic. If I'm writing, an example from something I did today, a number of functions to determine the income, in multiple currencies, from one season of time across multiple kingdoms, provinces, and holdings within those provinces, then I might do things like make it entirely granular, (everything calculates itself), and then provinces collect their holdings and kingdoms collect their provinces. But maybe I have exo-holdings in mind, (holdings in provinces outside the owning kingdom), so instead I write a function that collects the kingdom's tally of resources, the kingdom calculates income, and every other function related is slaved to that one. Maybe there's a lot of interaction between pieces, so I make a lot of non-mutating functions so that I can recalculate things (possibly with cached results), for when some other province or holding or kingdom needs it for its own calculations, (like a foreign bureaucratic holding embezzling taxes, or a domestic infrastructure project raising loyalty which allows a higher taxation level, or the rebellion in one kingdom reduces its guild, and thus the associated trade route, damaging the profits of all connected guilds of various kingdoms).
Generally, a person would pick one of these approaches, and another person coming in will either try to stick to that approach, or re-write it.
The AI will happily come in, and write all three approaches plus more I didn't think of across all of the functions, and after some cajoling, it produces the correct results.
Now, you come back to this sometime later and want to add Agricultural holdings and the trade of food to this all, producing gold, loyalty, and silo'd stocks.
You try to get the AI to do it, but it all fucks up.
Alright, you know how to code. First you try to get your new functions into the codeflow at the obvious place, but you discover that it's not always being called, and it's not totally clear why, or what *is* calling the seasonal tax routine. Eventually it turns out to be a curried function, which is a little odd, but makes a sort of sense. You start hooking the bits about food travelling down traderoutes, and interkingdom trade of food between over-developed provinces and agriculturally-producing provinces, but then you discover this function is non-mutative, and this similarly-named function isn't, so now you have to duplicate the latter one but in non-mutating form to get the data you need, or re-write it and all references to it. You choose to do the latter, but then it isn't entirely clear to you where it's *supposed* to be mutating or not, which rings an alarm bell because it was producing the expected answer, so why was it doing that? And then you discover the corrective function that has been un-mutating things to account for all the extra times that function was called & mutated when it shouldn't, and you can clean that all up and get rid of an entire function that didn't need to exist and your own code makes sense. And you get the expected results. But the debug log is now totally disconnected from the results of tax season. Which is really hurting your attempts to try and figure out why food being produced in one kingdom is being sold to another, (apparently? Maybe?), even while the first kingdom doesn't have enough food to feed itself. Now, it turns out in the end that it was actually a third kingdom feeding the second one, but in the meantime your agricultural holdings are producing the wrong amount of food and you've mis-identified the problem. So you fix the debug logs, getting rid of a lot of variables that only existed to be printed in the debug log and didn't even need to be there. But you fix them wrong at first because of the mis-identification, and then you spend a lot of time debugging the food trade code, but it's not the problem. Eventually, you realize every farm is producing as-if one level lower, and that turns out to be because communal infrastructure holdings built in other kingdoms count as 1 level higher for the purpose of espionage, (so that a level 0 holding still gives espionage bonuses), but more specifically because the AI code stores all holdings as one level higher than actuality, assigned contested holdings to be level 0, and subtracts one from everything's level during tax season, and you didn't know to account for that.
Hi, I pay my rent by fixing people's AI code for them so that they can continue to develop their software, usually video games. The code-fixing process above is fictional, I didn't want to out any clients, I did actually write code for tax season for kingdoms/provinces/holdings, but that was for my own TTRPG software aid and I don't use AI in my own code. If you've debugged AI code, you can probably already tell I have a lot of experienced cleaning up AI code and know exactly what it likes to do, (the above is based on cleaning up after a specific model, even, which some people might recognize).
I've read bad code written by people. I've read truly bad code by people who thought they were being very clever. I've read hyper-optimized code where I had to do deep research into the compiler to understand what was happening. AI code . . . is insidious. I can get used to reading someone's assembly code programming, recognize and trust their patterns and recognize their bugs. AI code, it doesn't actually have patterns. I know what it likes to do, but I can never trust that those patterns are buggy, or that those patterns are reliable. I can tell when I see human patterns that, oh, I need to look out for off-by-one errors in this guy's code, I need to look for pointers grabbing the wrong offsets in this part of the codebase, I can get into a rhythm of predicting and finding many of their bugs before even figuring out what's happening. With AI code, there's not even necessarily any line or function that's "bugged", so much as there was never any logic to how anything was constructed in the first place. I often to need to understand the whole system to fix what would, for a human codebase, probably be fairly trivial to find and sort out. If a human could code like AI, they would be exceptional: they would have to be able to hold the entirety of the codebase and the program state in their head, and almost certainly as a result when actually writing code would produce very well-designed and well-executed code. No human would code like AI because there's no sense in switching logical approaches every function, and if they did, they'd be the type of person who would never be able to produce something that appears to work correctly at the end. (And the good ones up for a challenge would probably run out of creativity thinking up new ways each function could take a needlessly different logical approach).
And for this reason also, no collection of humans would ever produce AI-like code either. Whoever goes in last and cleans up the code would, well, clean up the code. You might, and often do, end up with several layers of design sticking around because no one ever cleans up fully, (and because of skew, they might not be able to), but there's lines of logic you can follow, and very often you start being able to recognize which programmer wrote which parts of a codebase because you can follow their logic.
If you had an infinite sequence describing the number of programmers working on a program with an amount of version skew that prevents redesigning and fixes memory locations and memory structures, then the limit of that function would resemble AI code.
And that's the trap of it all, really. It seems to really save you time, it seems to get everything right, and then one day it suddenly stops helping you at all because it can't read its own bloody mess, you can't read its bloody mess, you can't add the feature you want to your codebase, and you have code that looks like a million competent engineers wrote it, each with their own idea how, and none of them cleaned up anything or tried to adopt anyone else's approach. And then you hire me, and I'm able to afford another tattoo and a night on the town with a partner.
(and yeah, very often I just delete the code entirely and start fresh rather than trying to clean up the AI codebase. It's just faster that way.)