Lurker News
There are a couple of engineers on my current team that I can only describe as being a little too smart for their own good, and I'm struggling a bit with how to work with them. I've worked with this sort of engineer on previous teams as well, and they all share a few traits:

- They're brilliant, I mean very smart people (in an almost academic way?)
- They have a big appetite for adding complexity to systems
- They also have a big appetite for adding work to their own plates
- Their code has no consistent style
I work in embedded systems, so I'm generally writing C for resource-constrained systems. This sort of environment is rife with footguns, and I spend most of my time just trying to avoid those. A big part of that is keeping the things that my team controls as simple as possible, and while we are resource constrained, it's a balance. The tension comes when someone's more than happy to, for example, implement a complex caching scheme from scratch to save a few hundred bytes here, a handful of microwatts there. To me, adding that type of complexity for those sorts of performance improvements is missing the forest for the trees.
When an engineer like this proposes something that adds unnecessary complexity, it's usually hard to argue with. The proposed change typically does indeed make the system objectively better, and they're the one taking responsibility for doing the work and ensuring its correctness. But the overall system becomes a little more brittle, and a little harder to reason about, two things that are much more difficult to measure than memory and power.
Here's an example: an engineer on my current team recently proposed adding a significant feature to a module I wrote to make something dynamic that's currently statically defined at compile time. I pointed out that we could just change a couple entries in a static table to accomplish his goals, and we were able to avoid the extra work. What was notable, though, was his immediate willingness to write that feature. Maybe I'm lazy, but I'd sit there and think of half a dozen other ways to do it before settling on changing the module itself. But because he's smart enough to easily reason about a complicated solution, and he's willing to take on the extra work, he stopped there without weighing it against the larger system.
Have you worked with engineers like this? Do you have any thoughts on how to work with them in a productive and friendly way?
--
One more example if you feel like reading more:
In a past role, I got into a debate about code style with the smartest person I've ever worked with. It boiled down to me advocating for more whitespace in his code and him arguing that adding whitespace made the code harder to read. It took a bit, but eventually I came to understand that he is so good at reading code that he just wants it all laid out in front of him as densely as possible. He can effectively run it in his head, as long as he can see it.
That was baffling to me, I walked away thinking that I must be pretty bad at reading code. I use a very consistent style with long variable and function names, I keep my solutions as simple as I can, and I use whitespace generously to provide visual cues about the code's structure. All of this is to minimize the amount of brainpower I needed to understand my code, so I can put that energy toward thinking about the problem itself.

Comments (474) 222 threads

Show all comments

Showing thread 16 of 222

rgoulter3 replies#
> They have a big appetite for adding complexity to systems .... What was notable, though, was his immediate willingness to write that feature.

From your descriptions, it seems less about "adding complexity = good", and more about "solving things in a neat way = good" (for some definition of 'neat').
> Do you have any thoughts on how to work with them in a productive and friendly way?
I'm not sure you've articulated the problem very well?
It sounds like if they left & the code was handed to you, you'd be concerned about hard-to-spot bugs in the sophisticated code. -- But if the code & its correctness is your colleagues responsibility (& not yours), what's the problem?
> It boiled down to me advocating for more whitespace in his code and him arguing that adding whitespace made the code harder to read.
I think you came to the right conclusion about the differences. But, you might enjoy this blogpost from Steve Yegge:
http://steve-yegge.blogspot.com/2008/02/portrait-of-n00b.htm...

stingraycharles#
I think what you’re trying to say is that these types of solutions are fine, as long as they are decided upon by the entire team, and not just a single engineer: long-term maintainability is key here.

I’d also argue productivity is an issue: “neat” solutions may take much longer to develop, while the effort is not really justified. E.g. starting out with a system based on CQRS which is just a simple CRUD app.

noduerme2 replies#
Jesus fuckin Christ. I tried to read this blog post about how newbies make their code comments too verbose, and the post turned out to be longer and about as interesting as fucking Dianetics.

tl;dr, young programmers, ignore that schmuck. Please keep writing nice long comments to your heart's delight. You will thank yourself one day.

rgoulter#
> about how newbies make their code comments too verbose

I don't Yegge is trying to make this point.
Instead, he's making a similar observation to the discussion OP had about whitespace/code:
Yegge reckoned that someone who's very familiar with the program/domain will want to have very dense code, so then they can make as much use of screenspace as possible.
Whereas, for someone who's unfamiliar with a domain will benefit from seeing less code on the screen at once. It will be easier to digest.
I don't really see that as a value judgement where "comments = bad".

dusted1 reply#
One of us missed the point because I just added that to my permanent bookmarks as an excellent explanation of why some people write overly verbose (and hard to read and thus maintain) code, while others manage to write the same thing in a single, understandable screen-full.

" I would rather puzzle through a small, dense, complex piece of code than a massive system with thousands of files containing mostly comments and whitespace" <-- This, a thousand times. _I_ simply don't have the capacity to load giant nonsense class hierarchies into my head and actually execute such a program.. A small machine that I can actually see on on the screen, that I can manage..

noduerme1 reply#
really... if you've ever tried to write your own functionality into something like wordpress or bootstrap or whatever, you'd rather have that all in a single code file with less white space or comments? Would that make it easier to change the positioning of a particular dialog box? I thank God all the time for the white space and long comments left by writers of those kinds of libraries. Maybe those seem like trivial examples, but they're huge libs that don't often need a lot of changes; yet when you need to change things, they make it quite easy to find.

[edit] as I wrote that, I just realized that younger devs might actually look in horror on the idea of directly editing libraries like that for particular deployments because the tooling or shop mentality so forces automated upgrades that could overwrite custom changes... and institutional memory being so short, no one might remember the change some dev made to a bootstrap file. heh. But that's like someone calling themselves a mechanic without ever modifying an engine. You write a note, commit it with a custom marker like #weModifiedThis, and don't upgrade the library for 15 years or until you're dead or retired or the company goes out of business. Done.

dusted1 reply#
There's a balance to being overly verbose and isolating _EVERYTHING_ from _EVERYTHING_ to such a degree that it's a major travel all around the codebase to follow one little path through a single call, and cramming _EVERYTHING_ into one file.

I'm arguing for a balance.

Continue this thread — 1 reply

rowanG077#
Wow. I would LOVE to only work with "noob" programmers who nicely explain their reasoning for complex code. Comments are easy to ignore anyways.