r/ProgrammerHumor • • Nov 25 '22

Meme Coding strategies

Post image
52.2k Upvotes

385 comments sorted by

View all comments

Show parent comments

83

u/All_Up_Ons Nov 25 '22

The reasons are obvious when you think about it for a second. The projects that require temporary fixes are business-critical with tight timelines. The only projects with time for perfectly-crafted artisan code are unimportant ones.

23

u/BetterOffCamping Nov 25 '22

"we don't have time" is a logical fallacy that is usually just shorthand for "I don't want to deal with it" on management's part.

I find that when I simply do it well without "asking permission" I am able to get it done quickly enough to avoid uncomfortable discussions, and the inevitable feature changes are much easier to implement (thus faster turn around).

Good design focuses on generic enough code to be resilient to change. This is a result of isolating feature specific volatile code to small pluggable modules.

Often, some of the resulting code can be substituted in other areas of the system, further simplifying it.

4

u/qhxo Nov 26 '22

Never enough time to do it right, but always enough time to rewrite it ten times. Good code isn't just nice to look at, it produces value in terms of hours spent maintaining it.

3

u/TurboGranny Nov 26 '22

yup. People are always forgetting maint. cost

4

u/sleepyj910 Nov 25 '22

Exactly if you have perfect code coverage you aren’t working a critical project because no way you’d have time for that unless they give you a bunch of interns/juniors

1

u/TurboGranny Nov 26 '22

That makes sense. That said, I've had quick hacks that weren't to solve something critical, but to just make a problem go away so I could finish the main project only for tons of systems over the years becoming dependent on that thoughtless hack, heh