Which programming language should I learn?
August 24, 2009 1:34 PM   Subscribe

I'm totally intimidated by programming, but I think I need some not-so-mad programming skillz.

I'm a long-time (19+ years) system admin and all-round IT guy, mostly in Windows shops with a little Mac thrown in. I'm going to be laid off soon, and starting a job search at my age in this economy is intimidating. Since I have a couple months left on the job, plus a couple more months of full pay and benefits after that, I have some time to improve my marketability.

I'd like to get some programming skills under my belt. It's been years since I did any sort of programming (mostly BASIC or VBA, with a C# class thrown in a couple of years ago, which I've never used). Which of the modern languages would give me the most "bang for the buck," both as far as being easy to learn on my own and being the most useful for a potential employer (not knowing, of course, who that future employer may be or what they might need)?

I figure if I can get one language down, I can expand to another; but my self-confidence as far as programming is concerned is low and I'd really think something both relatively easy and relatively useful in the real world would be a good starting point.

If it matters, my home machine is a Mac, with Windows running in Boot Camp, so platform isn't much of a consideration.

Thanks in advance!
posted by lhauser to Computers & Internet (27 answers total) 12 users marked this as a favorite
 
C#--it has the benefit of being the best language and also the most marketable one.
posted by mpls2 at 1:46 PM on August 24, 2009


I like python. Its a pretty powerful scripting language and has an easy to pick up syntax, epsecially if youre used to C++/java way of doing things. It has lots of libraries and lots of tutorials on the net for free.
posted by damn dirty ape at 1:47 PM on August 24, 2009


I recommend Python, since it is relatively easy to learn, already on your system, popular, and applicable in a wide variety of situations.

There are numerous good quality and free tutorials available as well.
posted by demiurge at 1:48 PM on August 24, 2009


Python is easy to learn and great for home coding projects, but probably less marketable than C# or Java.
posted by qxntpqbbbqxl at 1:51 PM on August 24, 2009


The TIOBE Programming Community Index might be a good start, which lists the relative popularity of programming languages and general trends.
posted by meowzilla at 1:51 PM on August 24, 2009 [1 favorite]


I like C# because it has useful end-results to target: XNA Indie Games on the xbox 360, Silverlight on the browser, (?) XNA on the Zune HD, plus the windows desktop with plain WinFX (.net 3.0), plus of course ASP.NET.

That is quite an application range; and the tools have been state of the art since 1994 and the language itself is under more active development than any other.

To be hirable you need more than a line on your resume but solid examples of your work. Pick a direction and go.
posted by @troy at 1:57 PM on August 24, 2009


I've gone from rusty skills with C to putting together complete programs for the iPhone over the course of this summer, so my money is on Xcode and the Mac/iPhone SDKs. I started with Become an XCoder to dust off the old skills, then bought copies of Beginning iPhone Development and iPhone SDK Application Development.

After two months I can put together simple apps with user interfaces that display what are basically questionnaires and then use GPS functionality to store user input as a geographically-referenced entry in an SQL database. Working on doing some custom map drawing stuff using OpenGL since the included map functionality is lame and limits you to placing points as well as getting the app to communicate back to a central database. This is for a Master's project.

I absolutely love Objective-C and the whole idea of object oriented programming. When I learn something new, I can easily tack it onto an app I've already built to see how it works. My initial learning curve was quite steep, but once I finally understood the basics, I was able to quickly expand my capabilities by experimenting with all of the predefined classes the SDKs offer.

I have no idea what the employment opportunities are with a well-developed suite of Xcode skills. I have noticed numerous Craigslist postings in my area for help with developing people's app concepts or working an iPhone or Mac OS app up for a non-profit, making me wish I already had the requisite skills and some more free time.
posted by Derive the Hamiltonian of... at 1:58 PM on August 24, 2009 [4 favorites]


Keep in mind in a lot of cases the hard part of the language isn't the language itself but the libraries and frameworks that come along with the language. Python and C# are good choices but rarely are just writing some C# or python. More typically you are interacting with the gigantic set of libraries that Microsoft ships with the .Net Framework (databases, web apps, web services, data structures, etc.) or the stuff that is in python. Knowing how to make a class or how to do a loop etc. is nice but only gets you 5% of the way there. It amazes me the number of times I see people writing code that isn't necessary if they knew how the language libraries work.

So in short if I were you and wanted a Microsoft focus, I would study C# (and its libraries). I think learning something like python would be fun too. You can combine these two things to by the way with IronPython which is an implementation of python that runs on the .Net platform.
posted by mmascolino at 1:58 PM on August 24, 2009


I'd learn python. It's useful if you are already a sysadmin, used by Google, and is reasonably easy to get going with.

I don't think learning C# is worth your time. No one I know in the tech industry uses it. You'd be better of learning Java i'd say, if you want to learn a more corporate language. C# is essentially windows only, which also limits is use.
posted by chunking express at 2:03 PM on August 24, 2009


And Objective-C is definitely a good idea, as iPhone programmers can bill a lot of money right now. And you can develop your own software on the side.
posted by chunking express at 2:04 PM on August 24, 2009


I definitely don't have a whole lot of expertise here, but I've been teaching myself Python lately, and am really enjoying it. I think it's a good language to learn the basics of computer programming in general, and I've been able to apply what I've learned to MATLAB to some extent as well.

I'm still a total n00b, but I think Python is a great one to learn.
posted by solipsophistocracy at 2:05 PM on August 24, 2009


I will second Python (so long as you avoid the terrible Lutz book on it; I purchased the book before I tried the language and the impression it gave me was so ... well, I stuck with Perl nearly a year longer than I should have, if that tells you anything). If you have questions about Python against Windows, either hit StackOverflow or MeMail me.

I'll throw out something interesting, though. What about PowerShell? It caters to your sysadmin background while still being a programming language (I have no idea if it is Turing Complete, but I'll say "yeah, probably"). It would be useful to you if you're a sysadmin for a Windows shop in the future. I bought four PowerShell books I'm going through right now and, while I'm not a sysadmin anymore, there's a lot of "oh, that would be useful!" going on as I read them.
posted by adipocere at 2:21 PM on August 24, 2009


It makes a big difference what platform you plan on being a sysadmin for; if it's windows, there isn't much point in learning anything other than C#, ASP, or VB (and those are close enough to interchangeable that you may as well learn C#). If it's a mac, then python is probably reasonable; Objective C is probably not reasonable. It might be worth looking into applescript, too. (When you're reading other answers to this thread, pay attention to the people who are answering 'What is a good programming language for a sysadmin?' and who are answering 'What is the most awesome programming language to learn?')

Whatever language you learn, it's probably better to start with some specific jobs and go from there. There are a few kinds of standard programming tasks for sysadmins, any of which would be a good place to start:
- Process logs (usually web server logs) and run stats, like find the most common IP address, or the most popular page, or when the traffic spikes.
- Run a command on lots of other computers. This is trivial to do a simple version of, but gets substantially more complicated when you want to maintain groups of machines you can refer to by name, run commands in parallel, verify the command completed, or combine running the command with pushing out some files (possibly making those files machine-specific in some way, like writing the name of the machine being pushed to into a config file).
- Have an application running on one computer that is monitored by an application running on another computer. The most basic form of this is a web server that you just check to see if it's alive; more advanced involves proving the application is actually responsive, or even checking whether it's served content to the outside world in the last N minutes.
- A simple web page of some kind, probably to do one or both of the previous tasks. Have a page that shows the status of all the web servers in a cluster and whether they're in status normal or not. A page that lets you click a button to push out some content to all the servers (be careful with this one! How would you do security for it?)

In general, programming skills make the difference between an okay sysadmin and a great one. The situation on windows is a little more complicated -- things are harder to automate and fewer people know how, but you look more awesome when you do manage it -- but the maxim still holds true there.
posted by inkyz at 2:31 PM on August 24, 2009 [1 favorite]


I don't think learning C# is worth your time. No one I know in the tech industry uses it. You'd be better of learning Java i'd say, if you want to learn a more corporate language. C# is essentially windows only, which also limits is use.

That depends on what part of the industry you're in. There are tons of Windows shops out there, and most of them are very C#-heavy.

Python can be used for many purposes in both Java-only and C#-only environments, of course (through Jython/IronPython, or for separate "scripting" tasks) - and in the OP:s case, perhaps make it easier to get over the initial barrier.
posted by effbot at 2:34 PM on August 24, 2009 [1 favorite]


I'm a long-time (19+ years) system admin and all-round IT guy, mostly in Windows shops with a little Mac thrown in.

What about PowerShell?

Powershell would be very useful for Windows. For a windows sysadmin, it and VBA are the most useful job-wise. For Mac, of course, it's useless.
posted by I_pity_the_fool at 2:35 PM on August 24, 2009


If you're not already, become a command-line ninja. Really take the time to master the core *nix tools, like awk, sed, cut, sort, etc. Throw in a little bash scripting and you'll be amazed at what you can do in just a few keystrokes from the shell.
posted by chrisamiller at 2:48 PM on August 24, 2009


Python is awesome (though I prefer Ruby) but not particularly useful in terms of employment right now, unless you plan to work at Google or somewhere else with a strong scientific or open source ethos. I suspect you're not planning on going in those directions. The same applies to Ruby unless you're looking at getting into the non-Windows platform Web app game.

So.. C# or Java - depending on whether you want to head into a Microsoft shop or have a more general outlook. People bitch and whine about Java all the time though, even hardened Java developers, so if a lack of pain is what you're looking for, beware.
posted by wackybrit at 2:50 PM on August 24, 2009


nthing Python (a million times python). Python for Sys Admins

It's super-powerful and sometimes feels like pseudo-code. Learn some Django.
posted by i_am_a_Jedi at 3:02 PM on August 24, 2009


You've gotten two answers so far, and they're both right, depending on what kind of career path you want.

1) Java / C# - Good if you want to become a full time coder.

2) Python / Powershell / Ruby - Good if you want to become a sysadmin who knows a little code.

So pick whichever one describes what you want to be. Learning python is probably a good approach if you want to be a good sysadmin, since it's generic enough that you'll be able to pick up perl or ruby, or whatever is at the new job, already in place.
posted by cschneid at 3:08 PM on August 24, 2009


Powershell would be very useful for Windows. For a windows sysadmin, it and VBA are the most useful job-wise. For Mac, of course, it's useless.

There's pash, although its capabilities tend to be over-promised. Ignore the fact that the latest release is labeled "1.1", it's really pre-release software, but it can do many of the basics.
posted by XMLicious at 3:32 PM on August 24, 2009 [1 favorite]


Python, Python, Python! It's a great language with some really useful data structures. I picked it up while working at a previous job to handle some log processing, and not only was it relatively straightforward to get the basics, but it worked really well in the task I was trying to accomplish.

It's harder to say what languages will help you get a job, but if you're able to use a language like Python as a gateway to help you feel more comfortable, you might find learning additional languages easier. Plus, Python is sweet. :)

Good luck!
posted by swrittenb at 5:35 PM on August 24, 2009


I pretty much agree with cschneid: Python, Java, and C# are all good bets, but your choice is really going to depend on the thrust of your job search. If you plan to stick with more of the Windows IT shop role for instance, C# and the .NET Framework probably make the most sense.

As far as the intimidation factor, all three of the above languages have been around for quite a while, and as such there are many educational books, across a spectrum of skill levels available to you. I'd figure out which language I'd like to dive into, then go down to the local Borders, or whichever one has a decent tech section, and just start thumbing through the 15 books they're going to have on the language, pick the one that seems best suited to your skill level and comfort, and go from there. Good luck.
posted by Brak at 5:39 PM on August 24, 2009


What I sort of implied in my previous post but didn't explicitly state is that I believe you can just as easily learn Python as Java as C#; I haven't found that one of those is especially more or less accessible than the others.
posted by Brak at 5:43 PM on August 24, 2009


Get on to whatever websites ( monster / craigslist / etc ) you can to look for jobs and build up an index of the number of jobs on different languages.

The Tiobe index is useful, but it may well not reflect the job market. Check your area's job ads.

When doing this you could use a programming language to automate it.

I run something like this and have been for a number of years where I am. The language popularity at the moment is .NET / ASP / C# at #1, Java #2 . Also worth noting is just how many jobs need SQL. There are more positions with SQL in them than either .NET or java.

Python is a cool language, but there are not a lot of jobs out there for it. Where I am there are hundreds of times more jobs for java, C# or C++ than Objective-C.

All these numbers should be taken with a grain of salt of course, it's just what I can see. Work out how it is where you are.

Learn something. Programming skills are transferable between procedural languages. If you learn python you'll be able to pick up C# more quickly and vice versa. So get onto something and get into it. Something that appeals to you is important to. If you're interested you'll learn it more quickly.
posted by sien at 5:57 PM on August 24, 2009


Python because it's nifty, and Javascript because it's nifty and already installed on everything.
posted by flabdablet at 7:31 PM on August 24, 2009


Unless you're planning on a career change (into full time programming) something like Python might be your best bet. Python in particular is good on Mac (it has a rich set of interface libraries), good on Windows (it has libraries for things like COM which would allow you to automate, for example, Active Directory changes) and good on Unix, where it began.

C# is good too, but most of the jobs in that area involve pulling bits out of a database and either displaying them on a web page or in a window. If you don't have an intrinsic love of programming that may not be your thing. Python (and similar languages) are also much more suited to gluing things together quickly.

Don't look past C; it is still widely used for legacy systems (which come with great job security if you end up enjoying maintenance work), and more importantly in embedded work. Also, it is the foundation for Objective C, which is the primary language on Mac OS X. It'd also give you an edge for Unix administration, since much of the software there is still C.
posted by ianbanks at 9:45 PM on August 24, 2009


good on Unix, where it began

Footnote: The original development of Python was done a Mac, with the Amoeba operating system in mind.
posted by effbot at 9:02 AM on August 25, 2009


« Older Hiring a nanny, need info?   |   Switching from TIAA-CREF to VALIC? Newer »
This thread is closed to new comments.