Which Language Should I Learn?
Where do I start?
There are so many programming languages out there, it can be difficult to know where to start in terms of which language to learn. Each language will have its strengths and weaknesses in terms of capability, whether that's because of the libraries designed for the languages, how it is compiled (if at all!) and even license fee.
If I'm not sure about what I should focus my learning on, I first think about what I need for the job I'm in. If I'm not in a job or I'm after something a little different but that would be useful for my future, I take a look at the job adverts out there for things I think I'm interested in/might be in the future. In the Data Science/Machine Learning world, I think the two most common languages you see are R and Python, and sometimes backed up with SQL if you're going to be querying databases. Depending on the role though, there may be a call for other languages such as Java, GO or even a C based language.
It's most likely obvious from my posts that I am in the Python camp, to be honest this is because it was the first programming language I learned and it's what I've been most comfortable with throughout my academic career. It just made sense to try and get better at Python rather than try to learn another language, especially when it's one of the most sought after languages in this industry. It just sort of fitted for me. If you've read my first post on here, you'll know I sort of fell into Machine Learning Engineering, because that's where my skillsets sort of fitted to. Including, the programming language I'm most comfortable with: Python.
From my experience, if you're going down the MLOps route, Python is a must. However, if your goal is to work in other aspects of Data Science and Machine Learning, then R might well get you where you want to be.
Learning a new language
That's not to say that you should despair or feel like you've wasted your time if you know a different language. What you know is transferrable, there are a lot of terms and concepts that translate across languages. So you're not starting from scratch. For instance, a function is a function with the same concepts across multiple languages even if they are implemented slightly differently.
Keeping up your skills in languages you already know definitely won't disadvantage you when it comes for looking for work. So there's no need to give up on them, but if you're looking to break into Data Science and Machine Learning it would be good to have a go at some Python (in my opinion this is the language with the most potential and AI libraries made for it). Python is open source and free to use, in fact if you're a mac user you'll already have it installed on your computer when you buy it!
There are plenty of free (and paid!) resources out there to learn different programming languages, if you're going down this route. Youtube is a great place to start if you like video learning, also blog guides too. There are a lot out there you don't have to pay for. The one thing I'd say though, is get stuck in and do the code yourself. Don't just read a blog or watch a video. Go through the motions.
I would recommend Kaggle courses as a great free resource to get stuck into programming and Data Science concepts. They're free and there are some exercises to work through. Not to mention all the competitions and datasets and support from the community! If you have access perhaps through work or you want to pay for a course, DataCamp is a good place to start (and more affordable!) and if you're wanting something more in depth, you could try Udemy or Udacity.
The best tip I've had if you're already familiar with another programming language is rewrite a project you've done in the language you're trying to learn. I'll be honest, I've only done this with some simple functions (I was learning JavaScript) but I found it helpful to understand how languages are structured differently and what I call their "quirks". If you've done this, particularly for bigger projects, please let me know how it went for you!
Master of one?
Another question that is often asked/pondered over: is it "better" to know one language really well or is it better to know a bit of several languages? Well, firstly I hate the word "better" because it really depends on what is needed for individual circumstances e.g. requirements of the job you have/want.
That being said, the advice I've got over the years is to get really good at one language (preferably the one most relevant to your job needs/aspirations). That's because the more in depth knowledge you have in a language, the more complex things you can tackle and understand. This knowledge is then transferable to other languages you need to learn, even if it needs a bit of tweaking.
To give a simple, but concrete example: if you can assign variables and print a response in 3 languages, that's interesting and a start in 3 languages. But, how useful is that going to be in a larger project? If you can ALSO use flow control and write functions and classes in 1 language though you can start to build a bigger project efficiently. It shows that you understand more complex concepts and can actually produce something more meaningful. If you need to do that it another language, you're not learning all the context and concepts to do it, just a bit of new syntax to implement.
In the end, the programming language you choose to learn is a personal choice. But, that choice might well lead you down a particular route, so it's good to be aware of that before you commit! If you're not sure where you want to be but want to learn to code, I'd always recommend Python because it's free, open source (so lots of support) and can do most things - even if it's not the best at everything, it's a way into most things you need code for. Happy Programming :)