3 ms·
Because it forces one to think things through instead of using trial and error.
by stingraycharles 17y ago
Because it forces one to think things through instead of using trial and error.
- derwiki 17y agoIsn't one of the advantages to programming over other disciplines that we can create unit tests that define "success" and iterate quickly until we get there?
- DLarsen 17y agoUnit tests are code too. What ensures the correctness of the tests themselves? My point is simply that you can't simply defer to testing as a cop out to avoid claiming confidence in the correctness of some portion of code. There has to be some amount of code that a dev can pretty well validate simply by inspection. (I'm not saying don't test.)
- abstractbill 17y agoYou say that as if it's a given you can only do one or the other. FWIW, I'm a pure mathematician by training - not exactly a shortage of experience in thinking things through. But I would have very low confidence in any code I had just written down, instead of building it iteratively, using a REPL.