Many people get excited about the idea of learning programming when they discover the possibilities programming gives everyone who’s able to grasp its rules and principles.
But often this excitement flies away when it becomes clear that the path to the point when you can confidently say that you know how to code anything you want might be quite long and convoluted. In order to avoid such a disappointment, you have to learn programming the right way.
Learning programming is hard when you do it wrong
Yes, learning programming sometimes can be challenging. And it’s definitely not something you can master in a day or a week.
But it’s not as hard as it might seem from the point of view of somebody who knows nothing about programming yet, but has the desire to learn it. You just have to know a sequence of steps you should take to make the whole process of learning programming as smooth and comprehensible as possible.
The worst thing you can do while learning programming is to jump from one topic to another without proper understanding of what and why you do. The only result you’ll get from such education is frustration and loss of confidence in your abilities.
Generally, a typical programming learning process can be divided into five consecutive stages. Focus on each of them one at a time, don’t hurry, and you’ll get to the point where you want to be.
Stage #1 (optional, but recommended): learn how the computer works
If you don’t have good understanding of how the computer works (for example, what bits and bytes are, and how data is stored on the hard drive), it would be very useful to fill this gap.
Otherwise you’ll always have the lack of understanding what’s going on with the code you write. It will limit your ability to catch bugs in your code, and even affect your ability to devise correct logic for applications you work on.
Stage #2: learn the basics of programming
During the second stage you will learn the most fundamental programming principles and notions. It’s what a variable is, what a function is, etc.
Don’t worry if you don’t understand what these words mean as you read this article — it’s not necessary right now.
All the concepts you will learn at this stage will be applicable to almost all programming languages.
Stage #3: learn a programming language
At the third stage you will learn some specific programming language: C, C++, Java, C#, Objective-C, Swift, JavaScript, Ruby, Python, PHP, etc.
Often this stage at its very beginning contains the previous one, since it’s likely that you’ll learn all those basic notions of variables and functions as they are introduced as parts of some particular programming language.
But it’s important to understand that they are not just the elements of this specific language you’re learning right now. This is a fundamental knowledge that will be applicable to almost any other programming language.
Apart from deep conceptual and philosophical things, which are not that important for most novice programmers, most (but not all!) popular programming languages differ from each other mainly in small syntax details. It’s about whether you use curly braces to divide your code into logical blocks or not, and other mostly decorative things like this.
So, if you successfully learned one programming language, you can quickly enough learn another one. Almost everything will be familiar to you, whichever language you’d like to learn next.
But don’t get stuck at this stage for too long. Usually it’s enough to have learned just one programming language — at least until you’re at the stage #5.
After all, programming is not a contest “Learn as Many Programming Languages as You Can to Win!” It’s not even about learning one language. It’s about using this language to work as a professional software developer or to create you own projects.
And, in order to create modern, feature-rich applications or websites it’s not enough to only know the programming language itself.
Stage #4: learn a framework for your programming language
Now that you know programming basics and some programming language, you have to learn some additional tools to finally be able to create real projects.
Theoretically speaking, you can start coding whatever you want even after the third stage, but it’s not how it works in the real world, and here’s why.
Whether you want to create a website, or a mobile application, or something else, it will be a fairly complicated product, requiring many different pieces which are not that easy to code, like the functionality allowing your users to log into your app. These elements are pretty much the same for almost every project, so it would be irrational that every programmer has to write them from scratch.
This is why software engineers created frameworks — software that provides you with all the basic logic and functionality you can build your own product on. Here are several examples of frameworks: Ruby on Rails for Ruby, Meteor for JavaScript, Laravel for PHP, Spring for Java.
Platforms like iOS and Android also offer developers who create mobile apps rich sets of tools to make their job much easier.
Using a framework, you write code only for those parts of your project that are too special to be covered by standard solutions this framework provides you with.
Frameworks save you a lot of time and ensure that the key components of your project are rock solid in terms of code quality and security.
Naturally, in order to use frameworks you have to learn how to use them first. Sometimes frameworks are so complicated that it takes more time to learn a framework than to learn a programming language this framework was created for.
Stage #5: learn something new about programming every day
If you reached this point — congratulations, you’ve completed your initial programming education! Now you can create real projects.
But it doesn’t mean that you don’t need to learn anything new about programming anymore. During your initial programming education you’ve created a solid base, and now it’s time to start adding new bricks on top of it.
You cannot learn in advance everything you might need to know about programming. It would be too much in terms of volume of information. Also, programming constantly evolve, so you have to keep your programming skills up-to-date.
It’s normal in programming to start creating a new product without full understanding of how exactly it will be implemented in code and what tools will be used.
So, read books and watch video tutorials about specific things you’ll need to use in your projects, read the relevant documentation, and, which is even more important, learn by doing. This is the best approach to learning programming after you’re initial programming education is completed.