I've gotten involved with some projects that help people to learn how to code and this structure lends itself to a successful follow-through into the job market.
I've also tried to teach homeless people how to program but the gap in computer literacy is just too big. Basic interface training is needed before any further progress can be made.
It's difficult, but in my experience, people starting something new thrive with structure. A small percentage of people would progress regardless but these are outliers in my data.
I have come into similar stories in other fields, specifically music. Where a structured course works for most, those that explore on their own eventually run into a hurdle they can't solve on their own and here's where one-on-one or problem-specific interaction would benefit.
Knowing what I know now, I think a structured path serving as a guiding light is necessary with the availability of problem-specific or exploration-friendly interaction would make for the best offering for people to teach themselves how to do anything, let alone something as abstract and intangible as programming.
I hope that helps in some way :)