Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Nice post. Short, sweet, and presented to avoid endless debates over particulars. (I know, I have plenty of my own.) I especially like:

I’ve found it’s often easier to keep a few broader ideas in mind.

Funny, OP doesn't mention the broadest idea of all: ego.

I've worked with hundreds of programmers and have sensed an inverse correlation between experience and openness to suggestions about maintainable code. I believe that the main reason is not that the more experienced developers are convinced that their methods are that much better (after all, there are often many acceptable ways), but that their ego won't let them "lose a debate".

When I return peer reviewed code to a young developer with suggestions (and reasoning!) about how to make it more maintainable, I often get a big thank you. The same feedback often gets a debate from a more experienced developer.

On the other hand, when someone gives me feedback and suggestions, my first reaction is to engage them and explain why they're wrong and I'm right. But as soon as I set my ego aside and think of the code instead of myself, I open myself up to learning. This is vital because what I don't know is always much, much more than what I do.



> The same feedback often gets a debate from a more experienced developer

Maybe that's because they have the experience they are able to debate it!

I think "maintainable" will always be debatable, because we are not using scientific methods to determine what is more maintainable. So we are all subjects to subtle biases like confirmation bias.

It would be great if we could use scientific method to determine how to write more maintainable code, but you would need a good definition of "maintainable" first, and that's hard.

Personally, I don't see much, if any, hard evidence that today's code (in 30 years to the future) will be more maintainable than the code written 30 years ago. I work on 30+ years old legacy codebase, which is often crazy complicated and effectively not-refactorable. But you can still fix bugs, you can add functionality. It's expensive to do, but not impossible. Would be the accumulated cost lower if people spent more time refactoring it, like today sometimes happens? Not clear at all.


While I agree ego and human nature can be hard to suppress, I disagree that this is the driving force here. It seems to me that having more experience necessarily means you are going to have a clearer sense of the 'right way' to do a certain task, and more concrete convictions as to why that is the 'right way'.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: