Live data from Hacker News

Ask HN: Code examples to find out if a person is addicted to “overengineering”

news.ycombinator.com

11–20 of 52 posts

Re: Ask HN: Code examples to find out if a person is addicted to “overengineering”

#12
post #5

How can you be so sure you aren't underengineering, and this person you know is actually planning ahead wisely?

Personally I feel as if underengineering is less of a problem than overengineering.

I've seen both in real life scenarios and usually you just throw the underegineered code away and start over with knowledge gained from the previous solution. And the reason you can do that is because you usually realize that you have an underengineered solution fairly early.

Re: Ask HN: Code examples to find out if a person is addicted to “overengineering”

#13
post #7

Ask them how they would, on a Unix system, do some task that's trivially done via a standard POSIX shell command. E.g. "how would you count the number of lines in a file?", "given a regex, please print lines in a file matching the regex", "given N lines, sort them by numeric value" etc. The most egregious over-engineering I see is someone writing a 100 line Python script for something that could be at most a 100 char…

That implies that you're interviewing for a position that requires Unix sysadmin tasks. Without knowing anything about your interviewee, he might've grown up programming only in Eclipse/Visual Studio/XCode/etc., and might not even be aware of the Unix tool suite. In this case, I wouldn't find it surprising that he uses the tools that he knows.

Re: Ask HN: Code examples to find out if a person is addicted to “overengineering”

#14

Have them build "A framework for X", where X is some commonly-done problem most programmers in their field have worked on (webapps, CMSes, forums, build systems, big data, etc.), ideally related to your business. If you want to do this in an interview or take-home setup, you will likely need to use a cut-down version of this problem, although really, much of the point of it is to see just how much the problem expands…

Thanks a lot!

Re: Ask HN: Code examples to find out if a person is addicted to “overengineering”

#15
I ask candidates to sketch an API (program, not REST, i.e. an outline of classes, functions and module structure) for a problem similar to those we solve, but smaller in scope.

I also ask about things like test coverage and programming paradigms they have an affinity for. Some things I look for that can be negative signals are:

* Propensity to choose classes and OO programming in a domain it isn't really suited for, or functional/procedural programming where OO might fit better

* Propensity to build for what might be rather than what is (e.g. always have an abstract class even if only one concrete class is necessary)

* Propensity to maximize test coverage (e.g. splitting the logic of functions into smaller ones just to generate test cases, even when those smaller functions are only called at one location) rather than to design for a solution

Re: Ask HN: Code examples to find out if a person is addicted to “overengineering”

#17
Are there actually experienced developers who still overengineer? I always thought of that as something that happens from the lack of experience. Straight from university developers, or people who never worked with a team before tend to do that, but I can't see how you will hold off this attitude after a bit of experience. And unless you're letting an inexperienced developer lead your team I can't see the problem. As long as the team leader eventually communicates and pushes an overengineer in the right direction (make it work > make it simple > make it generic), is this really a problem?

Re: Ask HN: Code examples to find out if a person is addicted to “overengineering”

#18
post #7

Ask them how they would, on a Unix system, do some task that's trivially done via a standard POSIX shell command. E.g. "how would you count the number of lines in a file?", "given a regex, please print lines in a file matching the regex", "given N lines, sort them by numeric value" etc. The most egregious over-engineering I see is someone writing a 100 line Python script for something that could be at most a 100 char…

You're assuming this person has in-depth knowledge of shell commands. If that's what you're testing for then fine, but I wouldn't say it's a good measure of over-engineering. They might have tons of python experience on Windows and haven't used grep in years, so that 100 line Python script might be the most efficient solution they can think of.

Also, any interview where I'm expected to have memorized obscure shell flags and one-liners with no access to so much as a man page can go fuck itself. That's just an IT/DevOps spelling bee.

Re: Ask HN: Code examples to find out if a person is addicted to “overengineering”

#19

Are there actually experienced developers who still overengineer? I always thought of that as something that happens from the lack of experience. Straight from university developers, or people who never worked with a team before tend to do that, but I can't see how you will hold off this attitude after a bit of experience. And unless you're letting an inexperienced developer lead your team I can't see the problem. As…

I have seen experienced developers that overengineer. It's hard to definitively know why, but I suspect sometimes it's so they can get some new "thing" on their resume or added to the approved toolbox for their team.

Re: Ask HN: Code examples to find out if a person is addicted to “overengineering”

#20
Ask them to make some simple yet non-trivial feature, like a contact form on a web page.

The overengineer will introduce a build system, several functional programming utilities, an HTTP client wrapper library, a DOM abstraction library, and maybe a full blown framework.

The competent developer will write a element with inputs.

Post reply on HN