The other day my dad asked me a question that I would have never expected from him.

"How can I learn C++?"

My dad is turning 56 this year and computers are a distant concept for him. He doesn't know how to use a phone very well besides calling numbers (no speed dial or contacts); though he has started to learn computers a little better - to the point that he knows how to open the internet (in Windows) and browse around (and has successfully completed several job applications entirely on his own online, of which he was offered positions too). But still, these are too narrow-windowed experiences to mean much, really.

While he may not have the background, my dad knows how to read. And I mean reading as a skill, not just an ability. He has little to no college education (financial problems, family, etc.) and was fortunate enough to finish high school, but still taught himself to become a master electrician and has been one for almost 30 years now. He did the same with guitar, learning to play at a very professional level and has been praised for his skill. In high school, he picked up a weight lifting book - and was the only person in his high school at the time to qualify officially as an "athlete" by national standards.

In all cases, he just needed something to read. Something to teach him. He absorbs information like a sponge.

I have no doubt in my dad's motivation or capability of doing this, so my general goal is simply:

Get my dad into the world of computers, and get him on the road to programming.

I strongly believe that once I get him through the fundamentals, his drive and reading skill will keep him going on this own.

So I'm asking you all: where should I start with all this? And what are the best resources out there? Should I get him to start Linux instead of Windows? Is C++ a bad idea?

Remember, he needs to (IMO) learn computers first, and then get that first grasp (the "Hello world" experience) of programming.

For money's sake and at top preference, I'd like free online resources that he can read, but by all means any good suggestions in print or paid-for-online are welcome (that I could possibly look into later to purchase).

And also, I intend to start him off with C++ (no Python, Java, etc.), because I know it the best and will be able to help him along the way with code. (I have minimal knowledge right now in other languages).

Edit: I'm getting a lot of persistent suggestions to use Python. The only reason I wanted to do C++ is that I KNOW it and can be THERE when my dad needs help. My VERY FIRST exposure to programming ever was Java. I learned Java, and I got good at it. I open to other suggestions, but please provide an effective application of your suggestions.

EDIT #2: I understand my approach/thinking/knowledge could be lacking here. I'm a sophomore level undergraduate CS major. If you don't agree with anything in my post, tell me why - give me ideas, information - that's why I'm asking in the first place. To narrow down my general goal to specific reachable goals.

  • 1
    This question does not relate to professional software development. Although in the course of our day, we have to interact with other people, technical and non-technical, and sometimes teach them, we aren't professional teachers or instructors and can't provide good advice on how to best teach someone. If you would like to discuss this further, you can raise a question on our Meta site. – Thomas Owens Mar 22 '12 at 0:53
  • @ThomasOwens how do you know no professional teachers or instructors exist in the community? Is the lesser viewed Meta really where I have to go? I guess I can give in to that (though I'd really like it to stay here), please migrate it for me. IF there's something I can do to make this question fit criteria to be better viewed by the SO/Programmers community, please help me do so. – skippr Mar 22 '12 at 0:53
  • 1
    To the best of my knowledge, there isn't a site that would accept this question. I just looked through the list and didn't see one. If you want to discuss this further, please raise a question on Meta. – Thomas Owens Mar 22 '12 at 0:57
  • @ThomasOwens Well, I'm not here to whine or troll, so I'll do my best with it. Thanks – skippr Mar 22 '12 at 0:58
  • Sneaking my answer in the comments...Contrary to the answers below I think C++ is actually a great first language. Especially for beginners. You start out with trivial console IO and C++ is much more beginner friendly than Java or C# in this regard. Less boiler plate code to confuse him too. Sure there are advanced features that will cause confusion but you can go very far limiting yourself to a few basic features. – Lord Tydus Mar 22 '12 at 2:44

First off, even if you do personally know C++ well, it's a horrible, horrible first language for beginners, and I cannot recommend strongly enough to keep him as far away from it as possible if he wants to successfully learn to write code. Learning programming is not about a language, it's about learning to express abstract requirements in formal logic. C++ makes that difficult to focus on because you're constantly tripping over language-specific issues.

If he wants to learn to express ideas in formal logic, go for something that makes that simple. My choices would be Pascal (for application-level development) or Python (for script-level work) because they're both designed with being intuitive and easy to learn as core priorities. Once he actually knows the principles of how to write code, then if he really cares about C++ specifically, he can pick it up.

For the same reason, don't start him on Linux instead of Windows, because then he has two problems to focus on: learning Linux and learning coding, at the same time! Keep the distractions to a minimum.

As for actual programming resources, it's easy enough to find tutorials online, but I've found that the best way to learn to program is by programming. Find something that you'd like to do, and then start figuring out how to do it.

Several years ago, I saw a game and I thought, "I could do this, and I could do it better." So I fired up Delphi and started figuring out the principles involved. I'm still learning new stuff from that personal project, and along the way, I've become a really good coder! So try that; ask your dad what he'd like to do if he could program--and make sure it's possible, and reasonably small in scope since he has no experience yet--and then sit down with him and start figuring out with him how to do it.

And if he has any questions, get him a StackOverflow account. :)

|improve this answer|||||

I think your dad's interest in C++ is definitely neat but it would not be my choice for a first programming language -- unless he has a very specific requirement that he is interested in meeting. (Even then, learning C++ after learning another, simpler, language might still be far easier.)

There's a handful of things that are important for programming:

  • The ability to solve abstract problems
  • The ability to decompose problems into small enough pieces for problem solving
  • The ability to build solutions iteratively and in small enough pieces that forward progress is possible
  • The syntax and semantics of specific languages.

In many ways, the syntax and semantics of specific languages is near the end of the skills necessary for programming. After all, if you're close to right, most compilers will tell you what mistake you've made -- though it takes experience to decode what specifically compilers are saying.

So, I'd suggest that your father tackle a far simpler programming language on the first go: Ruby, Python, C, C#, Haskell, etc. (Haskell is definitely difficult for people who've programmed only imperative languages, but I'd be curious to know if complete novices suffer the same "fish-out-of-water" feeling.)

Sticking with a simpler language up front means that your dad will have more success earlier, and will find it easier to "play". The interactive REPL loop of many languages is an excellent place to learn.

Once your dad is familiar with functions, classes, objects, methods, then the minutiae and nuances of C++ won't feel so overwhelming. Heck, even starting with C would be easier: it isn't forgiving, but there are fewer confusing features to worry about.

You're curious about Linux vs Windows; I'm not sure the distinction matters much. If he's already familiar with one or the other environment, switching is just another hurdle. If he knows neither, I'd suggest Linux, but mainly because installing good tools is ridiculously easy: apt-get install <foo> works on most distributions, and the distributions that don't support apt often provide something similar. A minute later, your neat new package is installed, often faster than it would take me to find a reliable download source for precompiled Windows binaries that doesn't reek of Trojan horses.

|improve this answer|||||
  • My dad definitely has that "ability to think" that is so vital for programmers. I see his common-sense and intelligence in the things he does now, and I know it can could be applied in programming. Let's assume we have an optimal candidate for learning. My question is: How do we get them there? – skippr Mar 22 '12 at 0:43
  • Hrm, I broke down the skills into different categories to make the point that getting bogged down on syntax and semantics can cloud the development of the other skills -- a language with fewer arcane-feeling rules will let the abstraction flow easier -- but I appear to have not stated that point well. – sarnold Mar 22 '12 at 0:48
  • 1
    Of the languages suggested, I'd certainly favour Python. But, if your Dad is visually inclined, Processing (see www.processing.org) might be an interesting intro (though there are many kinds of problems for which it is not suitable). – James Youngman Mar 22 '12 at 1:08
  • @James: heh, I don't think I've ever seen the phrase, Interactive programs using ... PDF output before. :) – sarnold Mar 22 '12 at 1:12

Not the answer you're looking for? Browse other questions tagged or ask your own question.