What programming language should I learn?
A lot of people who want to get into programming ask this question, and it's not a bad one at all! In this post, I'll try to examine the question and give a thoughtful answer.
I think this question is analogous to an aspiring musician asking "Which instrument should I learn?" The answer depends on your taste and interests. Generally though, I would say the answer is pick one that interests you and that will allow you to create the projects you want to create. If you like punk rock music, you should probably pick up drums, bass or electric guitar and not oboe or harp, right? If you're into data science, think Python or R, but probably not C++ or Perl (side note: with my recent experiences with the language, I don't think I would recommend anyone learn Perl).
If a language, like Javascript, piques your interests then go for it! Depending on your goals for your own programming practice, it's likely you will learn a number of languages as you continue your journey. Don't feel like the first language you learn will be the only language you learn, or that it will limit your options in the future. Also, if you don't like Javascript, you probably don't have to continue learning it. You can put it down for a while and see what else is out there. In fact, I would recommend looking at lots of different languages when you're first starting out, because then you're more likely to find one that "clicks" and that lets you express the ideas you're trying to express, or accomplish your tasks better.
If you're completely undecided, on the fence, or without any meaningful data points, you should think about which languages are popular. Not that this is a popularity contest, but it stands to reason that programming languages get popular for a reason. They're probably useful for one or more tasks that lots of people want to get done. Additionally, languages with more popularity are likely to have bigger communities of developers writing blog posts, tools, libraries, and StackOverflow answers. While you're learning, these can all be amazing resources.
Finally, for my own recommendation, I would personally suggest Javascript or Python. Javascript is great because with a few lines of it you can bend web pages to your will. It's also available as a "server side" language thanks to NodeJS. Python, on the other hand, is very general purpose and can be used to write web applications too (see my last post on "What is a web application?", process data and images, and nowadays is used for all kinds of Artificial Intelligence and especially Machine Learning projects.
As I said in the beginning of this post, you should research some languages, maybe try a few out, and ultimately find one that fits your general aesthetic and most importantly that lets you build the projects you want to build. You're only going to get better at programming with practice, and you're more likely to practice if you have a significant, meaningful project to work on. If you're excited to come back to that code editor day after day, you will learn more and faster than any other factor intrinsic to the language.
I hope this helps some people out there!
Comments
With an account on the Fediverse or Mastodon, you can respond to this post. Simply visit the post on its original server and leave your comment. It and other known non-private replies will be displayed below. Learn how this is implemented here and here.