Do you code like you drive?

Do people code like they drive? Photo of a car from a driver's perspective.

Correlation: a mutual relationship or connection between two or more things.

I think that, on average, South African drivers are bad. How many times have you watched someone jump a red light? Or pass another car across a solid white line? Or ignore a stop sign?

According to driversdomain.uk, South Africa is 6th in terms of world’s worst drivers. But there is no objective measure, so you can easily find us a better rating.

I often wonder what it would be like if people code the way they drive.

(Disclaimer: I’ve used the male pronoun for convenience. I’m only a little biased in thinking that young male drivers are more reckless.)

The impatient driver

This is the driver who speeds up when the light turns yellow. He changes lanes continuously to overtake cars during traffic jams. He is a frequent cause of accidents – which are guaranteed to really slow down his journey.

The impatient programmer doesn’t have time to comment his code. Or review it. Or test it. He rushes it to production. And then has to spend a lot more time fixing it afterwards. And there’s always some luckless person who gets caught up in the crash.

(The typical traffic light cycle is 120 seconds. So racing through the red light might save you a minute and a half. If it’s not a medical emergency, it’s not worth it.)

The aggressive driver

The aggressive driver yells at other drivers. He ignores the physics of following distances if the driver in front (or behind) him annoys him. He’s right, and the other drivers are a bunch of idiots. It’s unpleasant to be a passenger in his car.

The aggressive programmer know that his code is right. He might write great code, but he is definitely not a team player.

Next time you feel like yelling at an idiot, remember what it’s like to be the passenger.

The anarchic driver

The anarchic driver doesn’t believe that the rules of the road apply to him.

This is the driver who drives on the shoulder of the road to push in front of you. A few days ago I watched a driver pull into the wrong lane to overtake the vehicles in front of him, and execute a right-hand turn – in the face of oncoming traffic.

This driver makes your rage – and your blood pressure – rise. Maybe you edge closer to the car in front so that he can’t jump the queue. Maybe you fantasise about shooting out his tyres.

It’s hard to beat this driver unless you sink to his level. Or risk your mental and physical health. So the best strategy is to let him get in front of you and preferably far away, to avoid any fall-out from his driving.

The anarchic programmer doesn’t care about the rules. He doesn’t care about the user, the other programmers, the process or code quality. Avoid contact if possible.

The learner driver

The learner driver is nervous. So many things to remember. A car is an expensive, dangerous piece of machinery.

What about novice coders? They haven’t seen the results of bad code the way we have all seen the results of bad driving.

Learner drivers get lots of feedback. The car stalls. The other driver hoots. The driving teacher screams. But that big “L” on the back window means that most of us give the learners some space and leeway.

Novice coders get less feedback. Maybe their code doesn’t compile. Of course, it can compile and still be wrong. They don’t often have a teacher to grab the controls and correct their steering.

Without a big “L” sign, I’m not sure if other coders give them much leeway.

What about you?

I can hear you from here. “I’m a good driver”, you just thought to yourself. I hope so.

In case you were wondering, I don’t think I’m a great driver. (Although I did very well on an Advanced Drivers course.) I don’t like driving and it bores me. So it’s easy for my attention to wander or for me to get lost. But I try to consciously create good driving habits. Like waiting a second longer before pulling away to avoid the idiot speeding through the red traffic light.

When it comes to work, on the other hand, I can focus intensely for long periods of time.

Maybe it’s inverse correlation

I know one programmer who is careless and impatient with his code, but drives like the proverbial old lady. And another who is an aggressive driver, but a superlative programmer with amazing attention to detail.

So I don’t really think people code like they drive. Is there an inverse correlation? Honestly, I don’t know if there is any correlation at all. (So don’t decide to employ coders with a history of car accidents.)

What do you think? Can you think of better examples?

Leave a Comment

Your email address will not be published. Required fields are marked *

Thank You

We're Excited!

Thank you for completing the form. We're excited that you have chosen to contact us about training. We will process the information as soon as we can, and we will do our best to contact you within 1 working day. (Please note that our offices are closed over weekends and public holidays.)

Don't Worry

Our privacy policy ensures your data is safe: Incus Data does not sell or otherwise distribute email addresses. We will not divulge your personal information to anyone unless specifically authorised by you.

If you need any further information, please contact us on tel: (27) 12-666-2020 or email info@incusdata.com

How can we help you?

Let us contact you about your training requirements. Just fill in a few details, and we’ll get right back to you.