3 ms·
Make it write a test suite that you can manually verify/expand as necessary, just like code written by humans. I don't understand this 'but how do you know it w
by roel_v 4y ago
Make it write a test suite that you can manually verify/expand as necessary, just like code written by humans. I don't understand this 'but how do you know it works' argument. How do you know the code you wrote yourself works? I hope you don't rely on your superior programming skills to just get it right the first time?
- layer8 4y agoYou build a correctness proof in your head by thinking through all the details. That what takes most of the time, and the AI doesn’t relieve you from that. Of course one doesn’t always get everything right, but testing alone is no substitute for deductive thinking about the code’s correctness. And it’s also less fun having to do that for someone else’s code.
- simonw 4y agoChatGPT can help you that process if you ask it to. I often paste chunks of code into it just to get a detailed line-by-line explanation of exactly what that code is doing. It's really helpful, especially for convoluted code that you're trying to get a good feel for.
- layer8 4y agoThat’s true, but you still have to follow and think through all the steps of what the code is doing. With regard to new code, I don’t see the sometimes cited 5-10 times increase in productivity if you’re actually diligent about code correctness.