3 ms·
When you take an algorithm from a book, or copy and paste from stack overflow, you put a comment in the code with a link to the source, really no different than
by sentdex 7y ago
When you take an algorithm from a book, or copy and paste from stack overflow, you put a comment in the code with a link to the source, really no different than how you'd cite a quote in a paper.
To me, it just doesn't seem like it's even remotely challenging to figure out how to do this, or when to do this. If it's not yours, say where you got it.
When in doubt, cite it. What exactly would the harm be if you cited something when you weren't sure if it was necessary, anyway?
- celeritascelery 7y ago> When you take an algorithm from a book, or copy and paste from stack overflow, you put a comment in the code with a link to the source, really no different than how you'd cite a quote in a paper. You do this? That is very impressive. I have never meant anyone who did that. Myself included.
- SAI_Peregrinus 7y agoI tend to put a link to the SO answer in a comment. That way whoever is looking at it later (mostly me in a few months) can understand what prompted that solution.