3 ms·
>do you think it's better to add comments in as you write the code? Or add in the comments at a later date after the code is all written? Define "all written".
by konart 9y ago
>do you think it's better to add comments in as you write the code? Or add in the comments at a later date after the code is all written?
Define "all written". If we are talking about a new function - obviously you write you comment for it after the function ready to be commented on. And obviously you won't be commenting every string you put there, right?
Now, if we are talking about the whole new feature, that can consist of many functions and whatever - yeah, you usually comment your code in the process of writting the feature, rather than doing it at a later time, which will never come.