When you first start coding, one of the first questions you might have is what computer is best?

What computer should I use to learn how to program? You’ll need to install software development tools to write code and you can only do that on desktop or laptop computers with full operating systems such as Windows, Mac OS, or Linux. Even old computers are fine especially with Linux. You can’t use phones or tablets because they don’t have full operating systems.

There are several aspects to this question. You might be wondering:

  • Should I use a PC, or a Mac to code? And what about Linux?
  • Should I use a desktop, a laptop, or a tablet?
  • Can I use my phone to learn coding?
  • I have an older computer. Do I need to buy a new computer?

Let’s look at these one at a time.

Should I use a PC, or a Mac? And what about Linux?

The first question mixes together the type of computer with the operating system. I’ll first explain the concepts of this question and the next question before answering.

Personal Computers (or PCs) have been running Microsoft Windows for so long now that we normally think of them as the same thing. But Windows, Mac OS, and Linux are just operating systems (or an OS) and you can replace the operating system on a PC with any of several different varieties of Linux very easily.

I actually did this myself in 2018 when I needed a Linux laptop computer to bring to CppCon. You can read and listen to the full story about how I removed Windows and installed Linux here. And I also installed a full software development environment that you can read about too.

Apple has been selling various forms of Macs for quite a while too and whether it’s an iMac, or a MacBook, or a Mac Mini, inside a modern Apple computer is the same processor found in PCs. Apple also has their own operating system called OS X and it performs checks to make sure that it’s only installed on an Apple computer.

It is possible but difficult to install OS X on a computer other than a Mac.

You will need very specific hardware to have any chance of succeeding with this. Windows and Linux are less picky about what type of computer they run on.

The operating system forms the platform of your programming because it’s the job of the operating system software to interact directly with the specific computer hardware you are using.

When you write code, you’re actually writing code to run on a specific operating system platform. This is why you can’t install and run a Windows application on your Mac without something that knows how to understand Windows apps.

Should I use a desktop, a laptop, or a tablet? Can I use my phone to learn coding?

So now that you understand the differences between computers and operating systems, let’s add another variable to the mix. Should the computer be a desktop, a laptop, a tablet, or can you use a phone, or some other type of device that is yet to be invented?

What about an electronic device such as an Arduino or a Raspberry Pi?

While you can program “for” any of these computers or devices, you cannot always program “on” them.

You see, unless you intend to translate your code into the low-level machine code that the processors on these computers and devices can directly execute, you will want to use a development environment (and specifically a compiler) to help you program.

Modern development environments (called an integrated development environment or an IDE) are software packages that you install and setup on your computer.

While all desktop and laptop computers have this ability to install an IDE, not all tablets or phones or other devices have the ability to run a development environment.

Some devices have restrictions placed on them to control what software is allowed to run. Typically, only computers that can run a full operating system will have the ability to run a development environment.

If you have a tablet or a phone with a mobile or limited operating system that can support programming, then I’d really like to see it and maybe make another post with a review.

In general, tablets, phones, and other electronic devices are not suitable for programming. The can be programmed. But you will not write your programs directly with these devices.

Which one should I use when learning how to program?

Let’s answer the easy part first. If you are learning primarily from home then either a desktop computer or a laptop computer will be fine. If you are attending classes in-person, then you will definitely want some kind of laptop.

Normally, however, when people ask what type of computer to use when learning how to program, it’s the operating system platform that is really being questioned. In other words, should you use Windows, OS X, or Linux?

The answer is that it really does not matter which platform you have as long as you can install and run a development environment. It may make a difference for some programming schools. But at Take Up Code, you are learning more than just how to program on one type of platform.

You’re learning computer science and that means you will be able to program virtually anything because you’ll learn the fundamentals of what programming means. And you will learn how to think in your own mind about problems differently.

Even if you never intend to become a computer programmer, the skills you will learn about how to solve problems will benefit you no matter what you’re doing.

Some of the lessons at Take Up Code will be shown on a MacBook using the Xcode IDE and some will be shown on a Windows laptop using the Visual Studio IDE.

To help make things more uniform and consistent across the different platforms, There’s an IDE called CodeLite that can run on all three operating systems.

CodeLite actually has different versions for each operating system. You pick the version designed for your OS and it tries to behave the same everywhere.

The code itself that you write will normally run on any platform. That’s because you’ll be using standard code that is portable. You can follow along with your operating system and development environment of choice.

I have an older computer. Do I need to buy a new one?

So what about the age of your computer? Do you need a new one? No.

Although it will be easier to find development software that runs on newer computers, this is not required. Use what you have. Even if your computer is ten years old, you can still use it as long as it still works.

What do you think would have been used back then to learn programming? People were learning how to code ten years ago and your ten year old computer was brand new back then. You can still use it today.

You will find it easier if your computer hardware is a 64 bit system. This is about the only reason I’d suggest for you to get a new computer.

Many of the software tools are moving to 64 bit only and it’s getting harder and harder to find software that runs on older 32 bit systems.

Final thoughts about what environment is best to learn how to code.

One factor that you should consider is comfort.

Either when learning how to program or when working on your own projects, you will be spending a lot of time with your computer so make sure that you consider your comfort.

Don’t forget to select a comfortable desk and chair and a suitable environment with good lighting and few distractions.

And you may want to use multiple monitors.

Programming uses a lot of screen space for writing the code, running the application, researching topics, and reading documentation, etc. Having a large screen or multiple screens really helps.

Make sure that your monitors are positioned at the correct height so that you’re looking straight without bending your head to far up or down. I use a laptop stand that raises my laptop about eight inches above my desk.

Remember that the computer that you use to learn how to program is just one tool among many.

Use what you have and reposition things if you need to so that you’re comfortable.

Be prepared to learn more than just how to program. This is a new way of thinking and a new way to solve problems.

Ready to learn more about coding?

I’ve put together more than just a list of my best resources. These are mostly books because, well, coding involves a lot of reading.

Some are good reference material and handy to have next to you as you code.

And some are good for reading from beginning to end.

One of them is half and half. It’s half reading and the second half is reference.

And one of them is just plain fun.

But all of them are going to help you learn how to code better. How do I know? Because these are resources that I use and have gotten value from.

I hope they help you too,