Why You Should Use Linux to Learn Programming

linux-programming-teaserLinux is popular with programmers, and for good reason. Linux and Unix has long been a mainstay of computer science education for a long time. If you’ve always wanted to learn programming, whether you want to develop software professionally or just for fun, there’s no better platform to cut your teeth on.

If you’re still not convinced, here are a few reasons why you should use Linux (or any other Unix, including the BSDs) to learn how to program.

It’s Free

Linux is best known for the fact that all the distributions and most of the software is available free of charge. While Microsoft and Apple development tools can cost upwards of hundreds of dollars, Linux, since its user base is comprised of a lot of developers, has lots of programming tools available for free. Some distros have them pre-installed, some make them available through their package repositories. Browsing the available tools will make you feel, as Homer Simpson put it, like a kid in some kind of store. There are editors, compilers and interpreters for nearly every language ever created, debuggers, parser generators, you name it. If these programs actually cost money, you’d probably be able to buy a small house for the money you paid for them.

In addition, as Richard Stallman famously put it, these programs are also “free as in speech, not as in beer.” Stallman is best known for founding the free software movement back in the ’80s, which was an attempt to make sure that users could always get access to software that had the source code available. Whether you call it “free software” or “open source,” reading the source code to programs is the best way to learn programming. Imagine if you wanted to become a great writer but weren’t allowed to read any books. How could you be expected to produce anything worthwhile without knowing about the history of literature.


It’s Been Around Forever

While Microsoft changes its tools frequently, it’s an apparent attempt to simply charge their customers for their products by forcing them to upgrade.

Linux, on the other hand, builds on the Unix tradition by offering tried-and-true tools. You can pick up a book on Unix from the ’80s and much of it will still be applicable to a modern Linux distribution today. Although the GNU project and others have rewritten and enhanced many of the classic Unix tools, they still work pretty much the same as they did back in the ’70s and ’80s.

It’s Easy to Build Programs

One reason Unix and Linux has been popular with programmers all these years is that it’s incredibly easy to build complex programs without a whole lot of effort.

The most notable feature of Unix is the way shells handle input and output. It’s easy to send the output from one program to the other. A trivial example would be to send the output of the “who” command that shows everyone logged into a system into the less pager:

who | less

If you tried to code up something similar in C from scratch, you’d be looking at at least a thousand lines of code. The use of pipes, on the other hand, turns Unix and Linux into software LEGO, which lets you build complex programs out of a simple set of building blocks. This is also the reason serious Linux users prefer the command line. It’s almost impossible to pipe input from graphical programs.

If you’re thinking of getting started, why not pick a Linux distribution and start exploring today?

Photo Credit: Striatic

David Delony

David Delony is a writer for Make Tech Easier

Subscribe to our newsletter!

Our latest tutorials delivered straight to your inbox