> A straightforward solution of the problem is superior to one that makes you feel like a high priest for having discovered it.
It is also much better for the team and the company. Beginning musicians are just trying to play. Intermediate musicians are try to play as fancy as they can. Master musicians play what's needed by the tune.
It takes somebody who's past all the ego issues to devote their intelligence to making code look simple. It takes great intelligence to solve a complex problem in a way that looks simple and straightforward.
I’d love someday to hear a young coder tell a story about someone they idolized like, “There was this guy I worked with who once optimized a complicated red- black tree getting 300% performance boost. I was baffled and ask, ‘How’d you do that? That’s impossible.’ To which he responded…”
“‘That’s my linked list my son.’”
I believe that this is exactly what Niklaus Wirth did in the Oberon compiler.
Not unless he had a TARDIS at his disposal. I mean, skip lists were discovered in 1989, and by that time, the Oberon compiler had already existed for a few years. I don't recall the source now (I'd have to dig for it) but I believe that the Wirth anectode referred to his intervention in a case of overzealous students some time before that.
I found this part interesting, in contrast to his "expert amateurs" like Knuth:
> In contrast there are masters in the martial arts who learned their art as a means of survival and became masters in a realistic and hostile environment. We don’t have anyone like this in the programming profession, or at least I haven’t met any.
Any candidates spring to mind? John Carmack maybe? I'm sure there are loads though.
But Unix did, specifically from hard lessons learned from the failure of Multics. Sure, we now know some aspects of Unix to be suboptimal design, but that's with further decades of collective experience and even today the right answers are not yet entirely clear.
It's better for everyone who will use/reuse/maintain/improve that code in the future (including the person who wrote it). But of course it's not easy, and takes extra time.
Personally, at this time, I feel a lot more satisfaction when I'm able to truly understand the problem I'm working with, and refactor complicated/hacky/duplicated code into a functionally equivalent but simple and elegant code. Smart/complex code that works is a great intermediate step though, it's way better than no code. :)
Rob Pike has a very relevant article [1] on this topic.
> Smart/complex code that works is a great intermediate step though, it's way better than no code. :)
I'm totally with you on that. Often, the way to solve a problem is to first solve it wrong. In the process of doing that, you can see the way to solve it right. Trying to reach the endpoint in one fell swoop of envisioning and coding is actually another beginner move I've seen a bit.
What I'm totally not down with is complexity as an end goal. And yes, I've seen this mentality in programming.
It is also much better for the team and the company. Beginning musicians are just trying to play. Intermediate musicians are try to play as fancy as they can. Master musicians play what's needed by the tune.
It takes somebody who's past all the ego issues to devote their intelligence to making code look simple. It takes great intelligence to solve a complex problem in a way that looks simple and straightforward.