3 ms·
Something takes 20 hours to implement, but you do a hack job in 2 hours. Next time someone touch that code, they probably need to spend the 20 hours to re-imple
by z3t4 7y ago
Something takes 20 hours to implement, but you do a hack job in 2 hours. Next time someone touch that code, they probably need to spend the 20 hours to re-implement it. Technical debt can can be made less costly by using the test-first approach, you start by writing a test that confirms what you are going to implement works. When doing test-first, it's often fine to just do the bare minimal work. If something needs to be added/fixed, write another test, then do the bare minimal change, repeat. Eventually the code will be so complex a small change will take hours, and that's when you have to pay the technical debt, but if you have all the tests, you can make a clean re-write, and the tests confirms that the new clean code works just like the old code.