logoalt Hacker News

js8yesterday at 4:14 PM2 repliesview on HN

> requires an amount of time approaching the time spent if they had just done it themselves

It's actually often harder to fix something sloppy than to write it from scratch. To fix it, you need to hold in your head both the original, the new solution, and calculate the difference, which can be very confusing. The original solution can also anchor your thinking to some approach to the problem, which you wouldn't have if you solve it from scratch.


Replies

ummonkyesterday at 11:04 PM

In fairness though, it does give you good practice for the essential skill of maintaining / improving an old codebase.

bluGillyesterday at 4:32 PM

Sloppy code that has been around for a while works. It likely has support for edge cases you forgot about. Often the sloppyness is because of those edge cases.

show 1 reply