I’m pretty sure the short answer is: Become really good at Python. Learn additional languages if you want to solve a problem Python isn’t good for, you want to learn programming concepts Python doesn’t facilitate, you want to work on a project that isn’t in Python, etc.
Rationale:
I’ve seen lots of discussions online about what people think the best introductory programming language is. Python seems to be the clear favorite. (1, 2.)
UC Berkeley and MIT both use Python for their introductory CS classes. (Yes, both universities switched away from Scheme.) I don’t know much about any other universities.
Recently on Hacker News there were polls on what programming languages people like and dislike. Hacker News is the unofficial homepage of programmers everywhere, and thousands participated in these polls. According to two different ways of analyzing the data (1, 2), Python was the most favored language. Note that the poll was for general purpose programming, not best introductory language.
In my experience, it’s quite valuable to be highly fluent in your chosen language. For me, there seems to be a substantial productivity difference between a language I am fluent in and a language I am mildly familiar with.
The answer might change if you’re partway invested in learning some other programming language. I don’t know if it’s worthwhile to restart in midstream or not.
Also, one shouldn’t ignore the practical advantages of a batteries-included language (like Python) for enabling you to do things.
For example, if one wants to do some transformation of a spreadsheet which might be tricky or annoying to do in Excel/LibreOffice, one can just import csv and you’ve got a complete CSV file reader. Similarly, it’s an import and 2 function calls to get a file off the internet.
Similarly, it’s an import and 2 function calls to get a file off the internet.
I only count one function call:
import requests
f = requests.get(my_url).text
The built-in urllib and urllib2 modules can do this too, but they’re a disaster that should be buried in the ground. The general consensus is that requests is the Right Thing. You have to install it, but that should be easy with the pip package manager:
$ pip install requests
By the way, I agree with the recommendation of Python. It’s a very easy language to get started with, and it’s practical for all sorts of things. YouTube, for example, is mostly written in Python.
I’m pretty sure the short answer is: Become really good at Python. Learn additional languages if you want to solve a problem Python isn’t good for, you want to learn programming concepts Python doesn’t facilitate, you want to work on a project that isn’t in Python, etc.
Rationale:
I’ve seen lots of discussions online about what people think the best introductory programming language is. Python seems to be the clear favorite. (1, 2.)
UC Berkeley and MIT both use Python for their introductory CS classes. (Yes, both universities switched away from Scheme.) I don’t know much about any other universities.
Recently on Hacker News there were polls on what programming languages people like and dislike. Hacker News is the unofficial homepage of programmers everywhere, and thousands participated in these polls. According to two different ways of analyzing the data (1, 2), Python was the most favored language. Note that the poll was for general purpose programming, not best introductory language.
In my experience, it’s quite valuable to be highly fluent in your chosen language. For me, there seems to be a substantial productivity difference between a language I am fluent in and a language I am mildly familiar with.
You can hack on LW.
The answer might change if you’re partway invested in learning some other programming language. I don’t know if it’s worthwhile to restart in midstream or not.
Also, one shouldn’t ignore the practical advantages of a batteries-included language (like Python) for enabling you to do things.
For example, if one wants to do some transformation of a spreadsheet which might be tricky or annoying to do in Excel/LibreOffice, one can just
import csv
and you’ve got a complete CSV file reader. Similarly, it’s animport
and 2 function calls to get a file off the internet.I only count one function call:
The built-in urllib and urllib2 modules can do this too, but they’re a disaster that should be buried in the ground. The general consensus is that requests is the Right Thing. You have to install it, but that should be easy with the pip package manager:
By the way, I agree with the recommendation of Python. It’s a very easy language to get started with, and it’s practical for all sorts of things. YouTube, for example, is mostly written in Python.
Thanks for requests!