Be a better programmer in 6 easy steps
Image: nd3000

Be a better programmer in 6 easy steps

31 Jan 20181.51k Views

The best in their field are the ones who appreciate that there is always more to learn. Here are six steps to becoming a better programmer this year.

Coding is an evolving discipline. That’s often what draws people to it – aside from the opportunity to work with some of the biggest companies in the world – but it also means that those in the industry need to constantly look forward.

It’s not enough to get to grips with the most in-demand languages. If you want to advance in your career, you need to start thinking about how you can become a better programmer all-round, and these six steps are a good start (if I do say so myself).

1. Use the Feynman Technique

The Feynman Technique is a mental model named after Nobel Prize-winning physicist Richard Feynman.

It essentially boils down to identifying gaps in your knowledge by imagining you had to teach a concept in a classroom using simple language and analogies (much in the spirit of this subreddit).

When you identify the gaps, return to your books or whatever source of knowledge you rely on to teach yourself the aspects you’re less familiar with.

Then, just rinse and repeat, and suddenly you’re a lot more confident executing code because you have a stronger core understanding of it.

You can contribute to forums such as Stack Overflow to also employ the Feynman Technique. By answering questions and viewing the answers others provide, you will develop a deeper understanding of what you do.

2. Improve your soft skills

Soft skills may seem to be the total antithesis of programming (which is sometimes a central point of its appeal) but they are vital for your professional development.

If you’re able to communicate with clients and superiors alike in an accessible manner, as well as present yourself and your ideas in a pleasant and engaging way, you’ll find that many aspects of your professional life suddenly become easier.

If you’re worried that your soft skills are lacking, luckily they can be learned.

3. ‘Don’t be afraid to break things’

This advice comes from Mike Lewis, one of the many developers and programming experts who contributed to Kevlin Henney’s excellent 97 Things Every Programmer Should Know.

“Everyone with industry experience has undoubtedly worked on a project where the codebase was precarious at best,” Lewis explained.

“Whenever a module is added, the coder’s goal is to change as little as possible and hold his breath during every release.

“The reason that making changes is so nerve-racking is because the system is sick. It needs a doctor, otherwise its condition will only worsen.”

The idea of breaking something while you move things around may seem anxiety-inducing – no professional wants to end up making things worse, let alone a programmer – but if you’re willing to break things, you’ll end up with better overall code and, in turn, become a better coder.

4. Write code three times

Writing code has been compared to writing a novel and, just like in novel writing, you should never tout your first draft as your finished product.

By the time you finish writing code the first time, sure, it’ll work, but will it work well? It may be functional, but will it be elegant? If you aspire to elegance (which you should), try writing code three times.

Think of your first time writing as a proof of concept, your second time as you making it work and your third time as you making it work correctly.

5. Write lots of code in general

‘Practise, practise, practise’ is not a maxim isolated to the programming world, and for good reason. Coding is a skill like any other, and so the best way to improve professionally as a coder is to write a lot of code.

You can use GitHub to display your projects and then have other developers critique your work and provide guidance on how to approach things differently.

Then, compile your best projects into an impressive portfolio that will go a long way towards building your profile.

You can attend hackathons or join a pair-programming mentorship programme to hone your skills.

Consider contributing to open-source communities as a way to both build connections within your field as well as gain insight into the ways people approach problems that differ from your own.

6. Do unit testing

Unit testing can often strike fear and dread into the hearts of developers, but using it to design your code can ensure that every component of your work functions exactly how you intended.

As Steve Sanderson points out, programmers should not approach unit testing as if it’s a way to find bugs; just because components work independently doesn’t mean they’re compatible.

Unit testing is a key component of test-driven design. It makes the whole process a bit more time-consuming, which can be fuel to the fire if you’re already panicking about a fast-approaching deadline, but the end result is better-quality code that demonstrates your attention to detail.

Eva Short
By Eva Short

Eva Short is a Careers reporter at Silicon Republic who, coincidentally, was raised in Silicon Valley and has been nicknamed a ‘digital native’. Her passions include Pomeranians, witchcraft, skincare, wearing exclusively dark colours and eating. When she’s not writing about tech professionals, she’s working backstage at festivals, yelling at musicians, and amassing a collection of crumpled gig tickets to stick on her wall.

Loading now, one moment please! Loading