Bjarne Stroustrup–How Do We Write Good Code?
If that name does not mean anything to you than please see the nearest occupation consultant around. No seriously dude, you may not have heard that name since you are programming some kind of dynamic language, but still, man, go check. And in the meanwhile you should also check about Dennis Ritchie, who created the C programming language & was one of the creators of Unix. He passed away a week after Steve Jobs on Oct 2011 – That’s why his death didn’t get much attentions in the media as it should.
Bjarne Stroustrap (the creator of C++) gives a great talk about KISS (keeping it simple stupid) and how we as programmers cause things to be over complicated and generics even if we don’t use them eventually and even if they cause us to write terrible greedy code.
We know how to write bad code: litter our programs with casts, macros, pointers, naked new and deletes, and complicated control structures. Alternatively (or additionally), we could obscure every design decision in a mess of deeply nested abstractions using the latest object-oriented programming and generic programming tricks. Then, for good measure, we might complicate our algorithms with interesting special cases. Such code is incomprehensible, unmaintainable, usually inefficient, and not uncommon.
But how do we write good code? What principles, techniques, and idioms can we exploit to make it easier to produce quality code? In this presentation, I make an argument for type-rich interfaces, compact data structures, integrated resource management and error handling, and highly-structured algorithmic code. I illustrate my ideas and guidelines with a few idiomatic code examples.</blockquote>