I learned to code from the library. Checked out some books on programming and worked through them. I didn't even have a computer back then. Wrote my first programs with pencil and paper. Later I convinced a teacher to let me use the school district's computer and typed my program through a 30 cps teletype machine. Kids these days have it so easy.
Try Udacity, Coursera, MIT, and Standford Online for free computer programming courses.