New Year, New Language

The book ‘The Pragmatic Programmer’ suggests learning a new programming language every year. This may seem excessive and there are plenty of arguments for and against this. Whilst I don’t think you need to learn one that frequently, I do recommend learning a new language from time to time, or at least knowing more than one. This year I am dedicating some time to Python3. I already have Python2 on my CV, but this is now end of life and I have not used it much in the last 24 months. Although it’s not really learning a new language, I intend to spend some time learning the ‘pythonic’ way of coding with an aim of become more knowledgeable about the language specifics and supporting libraries.

Why Learn a new language?

As the saying goes,

‘If the only tool you have is a hammer, everything looks like a nail’.

For Software Engineers, having in-depth knowledge of a single language is great, vital in fact, but there are also many benefits of knowing multiple languages. Certainly the newer languages take different approaches, but it also ensures you are equipped to pick the right tool for the right job. Java and C# are great for large, scalable applications, but not so great when you just need to write a small script to automate something, or maybe a simple POC. This is where Python for example can come into its own, enabling you to solve the same problem, but with less code, in less time.

You don’t need to aim to be an expert, just start with the basics, but do ensure you use the language features as they were intended, rather than for example, writing ‘Java style’ code in a Python syntax.

Benefits

  • Increases your toolkit – Always a good thing
  • Keeping up to date on new trends and techniques
  • Can increase knowledge of exist languages, but comparing differences
  • Encourages and supports a learning mindset

How To Learn

Learning anything new is a challenge. There can be a steep curve where it’s easy to give up early on when things are tough. When you start, it will be slow and unnatural, this is where a lot of people will quit after a short period of time. In the book, ‘The First 20 Hours: How to Learn Anything … Fast, by Josh Kaufman’, he recommends committing 20 hours to learning anything new. This will help you push through the learning curve and make you less likely to give up. After 20 hours of purposeful practice, you should start to see tangible results and an increase in your abilities. Accept it will be slow at first.

Learn by doing, sites like Pluralsight are a great place for content, but ensure you complement this practically, by actually writing code and solving problems. It is vital to put the theory into practice. There are many sites out that that can provide small coding problems or Kata’s which are great to solve using a new language (I used the Advent of Code site last month, as a create way to start using Python3). You can even solve them using your old one as well, to compare and contrast.