Yesterday afternoon I attended a workshop held by Michael Feathers and Emmanuel Gaillot called 'Design Sense - Can We Teach Deep Design Skill With Perceptual Examples?' The aim was to see if, after developing for many years, we gain the ability to sense if code is good or bad just by glancing at it (the theory comes from Malcolm Gladwell's Blink). If it's true that we gain this ability over time, then perhaps we can find some way of sharing it with beginning developers.
In groups of eight or so, we went through tons of small code snippets and had to quickly rate whether we thought they were examples of good or bad code. The snippets were in different programming and spoken languages - some, like this one below, didn't even look like code.
0g:84*-!#@_801p0>_#":2%86*+\2/01g1-:01p0\#"_$$,,,,,1+
(It's actually Befunge)
I wouldn't say we reached any definite conclusions, but there were a few points raised that I found interesting: