DEV Community

Cover image for How to learn programming the real way
Ezpie
Ezpie

Posted on

How to learn programming the real way

When it comes to programming there are many videos on YouTube about how to learn to code, learn data structures and algorithms, and all those other things.

And if you're a beginner all that information would be too much for you to take, so here's my how-to-learn programming the learn-way trick, all the way from top to bottom.

Basics of...

Yeah, it depends, and it depends heavily on what kind of dev you want to be, mobile dev, web dev, ML engineer, game dev, DevOps, and all other devs devs.

Tip: What matters is not to learn a language, but to learn how to solve a problem.

Your job isn't to learn to code, it's first to understand the basics of problem-solving!

Believe it or not, I'm not good at coding, but what I'm good at is problem-solving and I can assure you that with this skill I can understand almost any programming language.

Here's a problem for you:

Given a list of random numbers say [1, 5, 10, 13, 17, 20, 23, 25, 35, 48, 55, 69, 78, 96, 100]. Find the position of 69. Assuming that is list is sorted

Comment below the answer and let's see what gets it first!

Did get what you just did? No? OK, so what you had to do was find the position of 69 in the list. Now there are quite some ways of solving it, but I won't show that, cause it's your problem, not mine!

Now if you spend at least 30 min on the problem you almost completed this post and can quit.

What I want you to understand is that programming is all about problem-solving, do you think those FAANG engineers by any chance create a new product? Well in most cases no, but what they do is solve problems, that is they fix bugs and security issues.

By this, it means most of their time is spent understanding the problem and then trying to find the just perfect solution that meets all criteria.

This is also the reason why most tech companies don't tell you a specific language to code on, rather they allow you to code on any language of your choice because all they need to see is, can you solve problems?

This is why at the on-site round companies also tend to use a whiteboard, rather than a computer with syntax highlighting and stuff stuff, to see if you can solve problems, so all you need to do is, understand the problem and you're now a highly skilled fully hireable high paying software engineer working at Netflex BTW.

No, that's not all you would of course need to learn...

Data structures and Algorithms

Yeah, no matter how much you all say we shouldn't have DSA in interviews... We will still have DSAs in interviews.

I mean take it from me, I'm the creator of an open-source social media app called Lambda... Yeah, you know where this is going(good old advertising!)...
As a matter of fact once I understand how to incorporate a company we will be hiring people, I have a bunch of questions ready!!!

So in case you want to learn DSA but don't know where to learn from, here are some options:

Just search and search and read about these things:

  1. Array
  2. Linked list
  3. Stack
  4. Queue
  5. Hashmap

Luckily I was able to find this nice YouTube video about Data structures and Algorithms... So go ahead and spend the next few weeks watching and learning from it.

Learn to create

Now you know about the basics and you may ask, "Wait wait wait wait! How is watching this random person programming on Java going to help me?" Well, you see, once again, it's not about learning to code, once you understand the problem you can find solutions in language.

You coded in Java, now go ahead and try to do the same thing in any other programming language, and you will see that it's almost the same thing, just a little change in syntax, which you can get used to within seconds, and I recommend to google the language and check w3schools for it's syntax.

With this info in your mind try to create something, maybe a simple todo app, yeah a simple todo app in say C++, or Java, or C, or Python, or god heavens JavaScript(even though I'm a JS developer!).

And you will start seeing things you learned from the DSA video, you will understand how to solve a problem, I mean like to store some todos, how are you going to do that? Of course, using an array! How are you going to add one todo? Using some algorithmic approach of course, so that even if the todo is different it will be added the same way.

So you see, even the simple calculator, or todo app you build will help you understand how to use those data structures, and how to go algorithmically about adding, removing, and showing data, just some basic things.

And of course that's just the basic implementation, once you get the idea of what you want, you can get fancy, like make an entire todo web app, or a desktop version, or mobile, or anything you want it to be.

So yeah, just learn to solve problems and learn data structures and algorithms, and you will start to understand how to code on your own, I mean look at me I can code in:-

  • JavaScript(of course, cause I'm a web dev)
  • Go(my personal favorite)
  • Rust
  • C
  • C++
  • C#
  • Java
  • Python

Yes I'm just flexing... again!

Top comments (0)