Live data from Hacker News

What is “good taste” in software engineering?

seangoedecke.com

181–190 of 245 posts

Re: What is “good taste” in software engineering?

#181

When used in the domain of fashion "good taste" describes someone who has a unique way of selecting clothes that just mesh well together - clothes that by themselves independently are meaningless, no matter their make or quality, but when combined together create a powerful effect - much greater than the sum of their parts. I was hoping the article would go in that direction - what subjective combination is a softwar…

Funny, I think it was one of the more insightful and well put together articles on a subject that usually elicits very hand-wavy unactionable statements.

Re: What is “good taste” in software engineering?

#182

Earlier quoted context omitted.

"Good taste" I have found comes from experiencing "good" API's and other "good" code. You know good code (and API) when you see it — and in time you should be able to write it as well. In short though, it's hard to have good coding taste when you are new to the field. (But, as you point out, it's not true that experience guarantees you will acquire taste — you have to both be looking out for it, recognize it, and be…

I'd argue the opposite, and go further and say there is no "good" code, only "not bad" code. I feel like most of what I think is good is because it's the only remaining option left after removing the "bad" ones. It's also way easier to find out why something is "bad" vs why something is "good" for some reason, not sure why. In the end, all code comes with tradeoffs, so I'm guessing we're really talking about good/bad…

It works better if you “split the axis”; (imo) good code is easy to modify, bad code is hard to understand. Everything else is, as you say, trade offs, and so only evaluatable within a specific context.

Re: What is “good taste” in software engineering?

#183

Good taste is writing code that looks so simple, everyone else says "pshaw, anyone could have written that!"

I have another example. I have a '72 Dodge Challenger. I've taken the thing apart, and put it back together. I never cease to be surprised at how well-engineered it is in its simple, direct, and inexpensive solutions to making an amazing car.

For example, consider the instruments. They run off of 5 volts, while the system voltage of the car is anywhere from 10-18 volts. How to get 5 volts? It has a sort of buzzer which is an electromagnet. When the voltage is above 5 volts, it breaks the circuit, when it is below 5 volts, it closes the circuit. It happens fast enough that the result is a rough 5 volts.

Many restorers of these cars decide to replace it with an electronic voltage regulator, that gives it a rock solid 5 volts.

Then they discover the instruments don't work.

It turns out that the (mechanical) instruments tend to get stuck. The roughness of the 5 volts keeps them from getting stuck. So now the the electronic voltage regulator needs another circuit added to make the 5 volts rough.

That little, simple voltage regulator hidden inside a can is a marvel of simplicity and effectiveness.

Re: What is “good taste” in software engineering?

#184

Good taste is writing code that looks so simple, everyone else says "pshaw, anyone could have written that!"

And the tragedy is that authors of such code often (usually?) don't receive recognition for saving time and effort on others' part by following KISS principles. For whatever reason its apparently opaque to others. And so there are entire jobs or even teams in the tech industry whose purpose is to work with and/or maintain systems that have needless complexity.

My life as the leader of the D team is one of a constant battle against complexity.

Re: What is “good taste” in software engineering?

#185
post #110

Earlier quoted context omitted.

> Readability is a non-concept really Yes.

Readability without a clarification is a non-concept. You can't say "X should be readable" without giving some context and without clarifying who you are targeting. "Code should be readable" is a non-statement, yes.

>"Code should be readable" is a non-statement, yes.

Oh, I completely disagree here. Take obfuscation for example, which you can carry on into things like minimized files in javascript. If you ever try to debug that crap without an original file (which happens far more than one would expect) you learn quickly about readability.

Re: What is “good taste” in software engineering?

#186

Good taste is writing code that looks so simple, everyone else says "pshaw, anyone could have written that!"

I have another example. I have a '72 Dodge Challenger. I've taken the thing apart, and put it back together. I never cease to be surprised at how well-engineered it is in its simple, direct, and inexpensive solutions to making an amazing car. For example, consider the instruments. They run off of 5 volts, while the system voltage of the car is anywhere from 10-18 volts. How to get 5 volts? It has a sort of buzzer whi…

Another example. The V2 rocket engineers had a problem with the nozzle. It would burn through. The flame was just way too hot for any known metal.

The solution was simple and pure genius.

The nozzle was composed of tubes welded together. The liquid oxygen was run through the tubes, which pre-heated the oxidizer and cooled the nozzle. But that still wasn't enough. Then the engineers simply drilled tiny holes in the tubes, so some of the oxygen would leak out into the nozzle. The gas would form a barrier between the flame and the nozzle, and would carry away the heat. (This is known as boundary layer cooling.) If you ever get a chance to look at a rocket nozzle, you'll see the tubes and the holes.

Re: What is “good taste” in software engineering?

#187

Earlier quoted context omitted.

Your phrasing makes it sound like you’re playing the same childish game they are; you just rank yourself higher than them.

There's nothing wrong with that. The problem is not that they were playing a childish game, it's that they were over-estimating their own abilities by a lot. It's ok to acknowledge you are good at something if you are, in fact, good at this thing.

> The problem is not that they were playing a childish game, it's that they were over-estimating their own abilities by a lot.

Why not both?

In an interview, you need to impress, and that's true for both the job-seeker and the hiring team. So yeah, you need to talk a bit about your accomplishments, and it's hard to do that without being a little braggy. But you can let your work be measured on its own. If you directly measure your accomplishments against the other person's, and especially if you put their accomplishments down, you're not selling them. You're showing off your personality flaws, even if you "win" the pissing contest.

Re: What is “good taste” in software engineering?

#188

Good taste is writing code that looks so simple, everyone else says "pshaw, anyone could have written that!"

I have another example. I have a '72 Dodge Challenger. I've taken the thing apart, and put it back together. I never cease to be surprised at how well-engineered it is in its simple, direct, and inexpensive solutions to making an amazing car. For example, consider the instruments. They run off of 5 volts, while the system voltage of the car is anywhere from 10-18 volts. How to get 5 volts? It has a sort of buzzer whi…

I think you've actually buried a much broader commentary on tolerances and complexity and interoperability in here, too.

The mechanical-averaging voltage regulator worked for the design because it only had to work in the context of the specific model of car it was going into. It didn't have to produce 5v for any application that needs 5v; it just had to produce "5v" for the instruments in the '72 Dodge Challenger. That makes it a pretty terrible 5v regulator, but a pretty great part for the system it was designed to fit into if the mechanical-averaging version is more reliable or cheaper or more robust than the fancy electronic versions.

But if I'm designing a 5v regulator to be sold as a 5v regulator, well... I don't know what system its getting installed into so I won't have much luck selling one that, over a long enough time span, averages out to supplying 5v of power when its supplying power. So I have to design in tight tolerances, and everyone integrating my regulator has to design for tight tolerances, etc.

The good news is that now anyone can buy my regulator and get a reliable 5v - interchangeable parts! But the bad news is now every system on both sides has additional complexity for the sake of complying with our standard.

We see this _all the time_ in software, especially comparing old software to new. Why is Roller Coaster Tycoon so much more elegant and efficient than a modern game written on Unity? Sure, good tastes probably factor in - but that taste from the author was allowed to shine because it was designed as a complete system, not a bunch of component subsystems from different teams and vendors stitched together.

Re: What is “good taste” in software engineering?

#189
post #59
post #20

> Is the software easy to take in at a glance and to onboard new engineers to? This is not as easy as it sounds. Who are those "new engineers", juniors? 10 years of experience? 30 years? What's your requirement? "Readability" is such a wildcard, with a whole range of acceptable levels from zero to infinity. Readability is a non-concept really. Maxwell's famous equations are readable to some and absolutely impenetrabl…

Readable code is code that has empathy for the reader and tries to minimize the cognitive load of interpreting it. That's one of the goals of abstraction layers and design patterns. Yes, it's all subjective, and depends on the reader's expertise and existing familiarity with the codebase. But arguing that code readability isn't at thing, because it's subjective, is an absurd take. Would you claim that Joyce's Ulysses…

The trap people fall into is calling The Cat in the Hat unreadable compared to Joyce's Ulysses because The Cat in the Hat they're reading is written in German and all they understand is English.

Re: What is “good taste” in software engineering?

#190

I have bad taste. So I will say suckless.org - software should do one thing and do it well - code should be understandable, easy to build, easy to port - dependencies should not be a problem - the chosen language must not be a burden - resources are scarce: if you say "unused memory is wasted memory" you are part of the problem (I know, I'm a horrible person)

Are you quoting suckless.org? Or paraphrasing? In a skim, I see some philosophy stuff there but not exactly this.

I think those are platitudes: they sound good but aren't specific enough that anyone disagrees with them, so they're not saying anything. Imagine:

> - software should do one thing and do it well

No one ever says "let's do a bit of everything, badly".

And there's tons of wiggle room in "one thing". Imagine a few, very different huge codebases. Let's say Linux, Photoshop, Rust. I think their proponents would say they're each focused on one thing (kernely-stuff, photo editing, foundational software). Their detractors would disagree: use a microkernel instead, separate out the filters or something, people are using it for scripting. Who's right?

> - code should be understandable, easy to build, easy to port > - dependencies should not be a problem > - the chosen language must not be a burden

Again, no one ever says differently, even if the result they end up with is none of these things.

> - resources are scarce: if you say "unused memory is wasted memory" you are part of the problem

I think this is the most interesting one, because it's contrasted with something I have actually heard people say (maybe even said myself on occasion). But still, I generally haven't heard people say it for no reason. There's some other attribute they're getting for that RAM, whether it's a compute-vs-RAM trade-off or the ability to use a (believed-to-be) simpler programming language or some such. This one might be more interesting if prioritized relative to "code should be understandable".

Post reply on HN