I am used to talking to people about programming and being told that it is difficult. Usually, the person making this statement doesn’t have any personal experience to justify this statement with. It is a matter of something that is “common knowledge”.
So, is programming difficult? In a word, no. It’s not more difficult than learning a foreign language. Of course, you have to be ready to sacrifice some time to learn, just like you would if you were learning a human language. Over the years I have introduced hundreds of people to programming, and I have *never* come across a hopeless case. (I have, however, met numerous people who weren’t able to get far because of real or imagined external causes. Usually it’s just lack of concentration.)
There are a few things you need to keep in mind while you are learning. First of all, to become a good programmer you must write a lot of code. Kernighan and Ritchie told us this already back in the early 70s, but many of us still don’t get it. When I learn a new language I start to write small snippets of code to get familiar with different aspects of the language. Within a few weeks, I will have collected hundreds of small code snippets. I normally try to solve the same problems in different ways.
You also need to enjoy what you are doing. Of course, you won’t feel motivated every day. At times, you will need to push yourself. But at other times it may be best to just forget about programming for that day. If you push yourself too hard, you may begin to feel that it becomes a chore, which would be bad.
I recommend that, if possible, you select a single programming language and spend a bit of extra time to learn it really well. It is totally irrelevant which language you choose. I know people who used assembly language, Pascal, C, BASIC, Java and a host of other languages as their first language and have ended up as good programmers. Choose a language that you feel you are likely to use, not something that some programmer tells you is a superior beginners language. (Trust me, that programmer has no clue of what they are talking about. It’s just a personal preference.)
Once you are familiar with the syntax of a programming language and have developed enough abstract example programs, you will need to be creative as a programmer. This requires other knowledge. For instance, if you want to program network monitors, you would have to know a bit about computer networks (er. forget the “a bit” part). If you want to write mathematical models of plinian eruptions, you would have to read up on your math and volcanology.
This is no different from acquiring a foreign language. Once you know the syntax and have a vocabulary of every-day expressions, you will need to pick up a specialized vocabulary that is relevant for you. For instance, if you are a chemical engineer and learning Chinese, you will eventually want to start learning chemical terminology in Chinese.
All this is not difficult, but requires that you make your mind up and take it one step at a time. But why then, does programming have a reputation of being difficult to learn? Part of it no doubt, comes from parts of the software development community themselves. In a society where we are blindly taught the religion of competition, most people would want to keep competitors out. Many people will stay away from a field that is believed to have high barriers to entry.
It’s also a matter of status. I think we all want to be accorded some respect by people around us. If what I do has a reputation for being difficult, something that requires more knowledge and intelligence than the average person is capable of, I feel good about myself. Never mind the fact that I may not really be as brilliant as I claim to be. Most “experts” aren’t.
Now go back and re-read this post. Each time you come across the word programmer, replace it with “doctor”, “journalist”, “geologist”, “dentist”, “politician” or whatever you want, and I’m sure the same still holds.