DEV Community

Discussion on: Is “Defensive Programming” actually healthy?

Collapse
 
cubiclebuddha profile image
Cubicle Buddha

Yes I agree, and thank you for weighing in. But I firmly believe that happiness comes from living in the present. So it’s a fun intellectual problem that I’ll be exploring in future posts.

My currently conclusion is that by being proactive in your code you can live more freely. And in a sense that’s the happiest way to live right now.

But I suppose one can go “too far” with defensive coding in which case it helps to have good teammates that call it out. It’s all a balance, right?

Collapse
 
robdwaller profile image
Rob Waller

I believe that's what Aristotle said. ;)

Trying to find a balance is usually the best approach.