I’ve been asking for interviews and insights on what programming languages different professionals recommend for beginners. As part of this series, Steve Pitchford also from Majestic SEO writes out answers to the question I’m always asking him- What programming language should I learn?
“Which Programming Language should I learn” is an interesting question – and the answer often says far more about the idiosyncrasies of the individual answering than it does assist the individual asking the question.
Many people will wheel out answers like “don’t program in language X” to mask an lack of understanding of a particular technology or some manner of unfounded or misjudged prejudice against said tech. I find it helpful to use the metaphor that a programming language is like a tool in a toolbox.
Many programming languages exist, and some are far more suited for some purposes than others – it may be easy to write a guest book script in php, yet inappropriate to attempt to code a retail site in the same language.
So I would avoid advice given by those who express extreme opinion about any given language – especially when it isn’t backed up with what appears justified reasoning.
The best answer to “which programming language shall I use” that I can think of is to reply with a question – “What do you want to achieve?” – I have found it a good idea to focus not on the language – but on a problem space, as different programming languages – like different tools – are often suited to different purposes.
The question “What do you want to achieve?” is interesting and worthy of further study. It’s important when first choosing a challenge to be realistic, to choose something easily achievable, in a field you find interesting.
Once you have decided on a simple first project – it’s time to look for your programming language. The question you are now passing around experts has now evolved – instead of asking techy people open ended questions that they may lack the social skills to answer appropriately, we are now in possession of something approaching a project brief:
“I want to learn a programming language to help me solve a suduko board – which language shall I choose?”
More focused questions like this often yield a more insightful conversation – you may be asked about how you want to enter the data – how you expect to view the response. Before long you will be breaking down your program into parts – considering data storage, processing and interface layout and thinking about all the important parts of software design which are far more relevant to the art of programming than the choice of which language to use.
Once you get into the practice of understanding and breaking down problems, and recognizing the roles of databases, code, and user interface in an application you soon find ( in my experience ) that the way of describing these interactions in many computer languages is similar.
That said, some languages are better than others at performing certain tasks – I’ll try to finish this post off with some rough guidence:
If you want to alter the format of files – such as re-arrange the data in a text file, or generate an excel file from some user input, Perl should be high on your list of languages to try.
If you are writing a desktop app, perhaps python, or visual basic would make a good choice.
For simple forms on webpages and small sites, PHP isn’t a bad starting point to try, but it may be worth considering python or ruby if you intend on growing things much larger.
Java is probably the best choice if you are keen on software engineering as a profession, or wish to develop an automated system to manage stock levels or other complex behavior. Java can have a reputation for being unwieldy or complicated, but I generally find that those who seek to criticize Java lack the commercial programming experience to see the benefits that good software engineering principals bring to a project. Java is also a key technology used on mobile devices – which may be a deciding factor for some projects.
Finally, there are some damn cool emerging technologies out there – node.js, scala and others – whilst these may be fantastic, interesting technologies, a beginner may be best advised to start with something a little more boring, more stable – bearing in mind that once our budding developers have found their way around one programming language, the second often becomes far easier to adjust to.
To ask Steve your own questions or find more of his sage advice, find him on twitter.