I actually agree with you to a point. My theory is we should bring back public execution, preferably by guillotine. It should be public, it should be humiliating, and it should be horrifyingly gruesome. I think it should be televised and I think watching a public execution should be mandatory for young high schoolers.
I absolutely think a public spanking or a day in the stocks might do more to straighten out some of young would be criminals than any amount of detention time in juvenile hall.
Unfortunately, regarding your idea on prisons. I live in Pennsylvania and that's exactly what was tried in Eastern State. Solitary confinement spent in contemplation of the bible, no speaking, no contact with anyone, was the conditions the prisoners were kept in there and they had an appalling number of them go insane.