4 ms·
I am rather conflicted to read this advice. I think we all want to do this; on the other hand, I think we also generally cannot afford the time to do it. In the
by glangdale 10y ago
I am rather conflicted to read this advice. I think we all want to do this; on the other hand, I think we also generally cannot afford the time to do it. In the project that I run, many major subsystems have been obsoleted by other algorithms, changes in the underlying hardware, etc. Every hour spent not writing beautiful literate code to communicate with other humans in these cases is an hour saved.
And yet, and yet.
- white-flame 10y agoEvery hour saved in skipping code readability is 4 hours wasted later in trying to reverse engineer what the code author was doing. Discarding on-the-job code with no maintenance or bug-fixing is astonishingly rare. Even building different parts of a system often requires some code updates in other portions, even if it's not even executed yet. Also, writing your thoughts into concrete, descriptive comments helps you with rubber-duck debugging, often pointing out weaknesses or edge cases you didn't think of when you were heads-down in the code. It's far faster to fix issues that come up ahead of time than after you've swapped it out of mind.
- otikik 10y agoI have been that second person many times and I agree completely with this comment. When you skip readability you are saving your own dev time at the expense of other future devs'.
- sqeaky 10y agoThat sounds like debt in time against the technical aspects of the system in question. If only we as an industry had some label for this Technical Debt so that we could appeal to practices like refactoring, unit tests and continuous integration to pay it down.
- vorg 10y agoAll business is about borrowing stuff from the future -- getting as much gain as possible now and deferring the costs as far as possible into the future, when someone else needs to pay back the debt, or when it can be defaulted on. Business managers don't let tech workers spend time refactoring because it violates this basic business principle. They will make up some other positive-sounding label, e.g. Agile Development, and bandy that around instead. When the system's technical debt is called in, those managers will have already moved to another system to pull the same con, or they'll replace the system with a fresh one complete with green-card-seeking programmers. The programmers on the old system will be retrenched without payment via stack-ranking, and their health problems caused from stress and lack of sleep forgotten about.
- pimlottc 10y agoEvery non-throwaway project involves communicating with another human, which includes yourself in six months.