| Learn C, then decide. 1. If you like programming logic puzzles then you will enjoy programming in C. In C, everything is a number, memory address, or byte array. So every "while" loop you write is a new logic puzzle! But seriously, the things that people tend to gripe about (pointers, segfaults, etc.) won't affect you if you are good at logical reasoning and learn your way around a debugger. 2. Learning C will teach you what's going on "under the hood" and make all other programming seem easy. For some reason people like to say the JavaScript or Ruby are great "beginner's languages," but I disagree. I think you should learn to drive stick shift first and then graduate to automatic. Too many people learn automatic and then think stick shift is unnecessary. Then when their friend with a convertible gets drunk at a party, nobody can drive home, and everyone has to sleep on the floor. If you know C, you will be the hero of the party, and if something deep inside the system breaks or there's a seemingly insoluble performance problem, you'll be the guy everyone turns to. 3. I see a number of growth fronts for C programming. A. Tablet programming. If you're not just writing Babe Alarm Clock apps and want to get the most out of limited hardware, you will want to know C. You might only write 5% of the app in C, but for critical logic paths, it can make the difference between an app that feels like a prototype and one that feels like a magic show. B. Desktop programming. The Mac App Store will completely change the economics of desktop software development. You'll be able to get a program in people's hands (and money in your bank account) with minimal expenditures on sales or marketing. This opens up a lot of potential for innovation and the creation of new vertical markets that people didn't think existed. Microsoft will probably follow suit with an App Store before long. For desktop programming on Mac or Windows, you will want to know C because: -- As with tablet programming, sometimes you need to write a critical logic path in C to get the responsiveness that users expect. -- The number of open-source libraries out there is large and continues to grow. In most cases, knowing C lets you take advantage of them, even if only to write a binding for some other language. In many cases you will be able to write a great program just by slapping a pretty face onto an LGPL library or two. -- GPU programming (OpenCL, DirectCompute, CUDA) looks to be an area of large potential growth, and as I understand it the APIs look a lot like C. For certain kinds of computations the GPU has 50X the throughput of the CPU. That's like going from a 66 MHz Compaq with a Turbo button to whatever 2GHz workhorse is sitting on your desktop right now. The ramifications for scientific computing are large; many programs designed around a "click and wait" paradigm can be rewritten to be fully interactive. There's a lot of potential for disruptive innovation here. C. Server programming. The web still has a lot of growing to do, and fast-growing web companies need folks who know C. Most people will tell you that for web programming you just need PHP or whatever, but when the going gets tough, you're going to bust out some C. When I was on the server team at a fast-growing chat company, nominally I just needed to know PHP and Perl, but I found myself needing C in order to: 1. Fix a bug in Memcache that was horking our graphs 2. Fix up the prediction algorithms in RRDtool 3. Write a PHP extension for monitoring CPU time on Windows. I couldn't have done any of those things without knowing C. If you want to be at a company that uses the latest and greatest open-source server technology, at least somebody will need to know C when you run into the programs' problems or limitations. D. Web programming. This is still several years off, but the Google Native Client is on the horizon: http://en.wikipedia.org/wiki/Google_Native_Client If it takes off, we're looking at a lot of desktop C/C++ code that will need to be adapted or rewritten to run in web browsers. 4. If you're hoping to be "very well paid" (esp. starting out at age 36) knowing C is a good strategy. First, it sets you apart from the stack of resumes touting Cocoa and jQuery knowledge. Second, knowledge of C is an excellent way to get involved in open-source and have your contributions widely used (and your coding skills validated). As a former boss of mine said, there are basically two paths to the major leagues in software development: first is to go to the right schools and get recruited into the right companies, and the second is to contribute to open-source. The most popular open-source projects are all written in C. On a personal note, I've had to learn a dozen or so computer languages at various points and I find C to be the most satisfying. It's a difficult language compared to most, but if you know it, like it, and get good at it, you can let other people worry about bullshit like CSS workarounds and concentrate on getting the most out of a computer. Knowing C will seem completely unnecessary as you get started on any idea, but as soon as you start thinking any of these thoughts: - "I've done everything, but it's still not fast enough"
- "I've done everything, but it still eats too much RAM"
- "If only I could use this library"
- "If only I could use this system call"
- "If only I could fix this bug" ...then if you know C, you will be the hero of your own party. |