There's also a phenomenon where gang bangers and the like "age out" — they just seem to stop. Unfortunately for many, this realization often occurs in the middle of a very lengthy sentence (they typically drop out, debrief, and enter protective custody).
Sadly, for many rehab isn't just a matter of wanting to do better. Very large numbers of the incarcerated can't do something as seemingly trivial as parse a bus schedule. Aside from undereducation, a fair amount are objectively unintelligent. When all you know is crime and you have a massive uphill battle just to be what many would consider a functional adult, recidivism seems inevitable for some. What makes it worse is that cultural reasons prevent many from reaching out for help while they're behind the wire. It's frankly sad to see, but we're getting better —the investments being made in tablets and the like will hopefully bear fruit in the coming years.
That’s only if there is no rehabilitation. The US system seems to be focused solely/overtly on punishment, which obviously means that whoever got locked up hasn’t had their mental state improved during the time of their lockup.