≡ Menu

Picking Your First Programming Language

A common question in many computer programming forums is “Which is the best programming language to learn first?”

There seem to be three common answers:

  1. What do you want to do?
  2. It doesn’t matter.
  3. Someone’s favorite programming language.

Some recommendations are obviously going to be biased, but the answer should be based on what you want to do as a programmer.

Are you into games?

Many young programmers are aspiring game programmers, usually ignorant of the game developer’s lifestyle, or at least that’s what I hear in forums and articles. Game programming is not gaming any more than racing cars is the same as mechanical engineering.

That being said, any budding programmer aspiring to get into games should learn C++. There are recommendations against it since it is such a huge and daunting language. But for a couple of reasons I disagree.

First, it was my first language. I did have a hard time, but then again I had a hard time learning the piano and the guitar. Being hard is not a reason not to do it. What really set it off was Joel Spolsky’s article on the Perils of Java Schools.

Joel’s article is his old-man-curmudgeonly complaint that universities teaching Java as an introductory programming language doesn’t do a good job of weeding out the bad programmers from school, and after a few months of programming I could see why.

There is nothing wrong with Java, but there are inherent qualities that don’t force the new programmer to think about what’s going on inside the machine. No pointers. No memory management (Java takes care of that for us). No crusty old programmer barking over our shoulder about the good old days of C and Lisp.

What if you want to develop Android applications?

Then start with Java. There’s also some XML but you can learn that as you go.

What about iOS?

If you want to develop mobile apps, but would rather code for iOS, then you’ll want to learn Objective-C (you’ll need a Mac for this).

My Recommendations

While I do agree that you should code with the language(s) you’ll need to build the programs you want, I do have a couple of caveats with that advice.

First, after getting your feet wet with your first programming language, I recommend learning at least one more—if not two or three or more—programming language.

You might never use that language once you learn to write some simple programs, but learning new languages teaches you to think about the computer and software in new ways, much like introducing a new exercise to you workout routine will challenge your muscles in ways they haven’t been tested before.

All that said, here are some of my recommendations for choosing a specific programming language:

C++: While it goes against many recommendations as a first programming language, many young programmers will choose it simply because it is the preferred choice of many game developers. Or they might approach it as I did—as a complex, difficult language—and so choose it for just that reason. I recommend C++ Primer (5th Edition) as an introductory text. There are also several online resources, such as cplusplus.com.

Python: This is MIT’s language of choice for their introductory computer science and programming course. Think Python: How to Think Like a Computer Scientist is another great introductory text.

Lisp: For the pure sake of learning a great language which you will likely never use—unless you plan on getting into artificial intelligence—Lisp is a good start. I recommend the free courses offered by MIT. There is also more recent Berkeley version of the course.

Java (if you must): The best introductory text for Java I have come across is Thinking in Java (4th Edition) by Bruce Eckel. There are also the New Boston Java videos.

Linux: Linux isn’t a programming language, but an operating system. The first place I would play around with Linux is the command line, specifically the Command Line Crash Course by Zed Shaw.

Objective-C: I didn’t forget about the Mac enthusiast. You will need a Mac computer to do it. Check out iDeveloper to get started. There is also a free Stanford class on iPhone application development.

In the end, choosing your first language shouldn’t be a big deal. If you feel you have chosen the wrong language, you can always switch, and learning a new language will get easier and easier.

Programming isn’t about languages; it’s about using the tools available (and making new ones) to get the computer to do what you want.

Just pick one a stick with it for a few weeks. It will likely make you a better programmer in the long run just knowing the language, even if you don’t use it ever again.

What are your suggestions for choosing a first programming language?

{ 1 comment… add one }

  • VBTutorial November 18, 2013, 4:28 pm

    I would honestly say that it doesn’t matter too much as long as the language is readable by humans. Some are definitely more intuitive than others. Ruby or Python are great elegant choices, but I’m probably biased towards my favourite. Bet you can’t guess what it is :-)

Leave a Comment