+ 9
What clean coding habits do you see yourself accidentally forgetting?
I personally have the issue of making a code work but forgetting to put notes in so I can figure out what i wrote!! So if you have any bad coding habits you feel like sharing please do!
4 Respostas
+ 10
Chance Page below should be followed:
1.code comment
2.error handling
3.proper meaningful variable names
4.standard methods awareness to avoid doing same thing weirdly
5. Following oops concept and simply avoiding mere function based coding
6. Function should not be too long and same way , class should not be too long
7. Free dynamically allocated memory
8. avoid Unnecessary use of global variable
will add if recall few more
+ 6
I am forgetting my indenting style b'coz most of code editors just do it without our efforts. when using Sololearn code playground it's not a case.
+ 5
I tend to write too much code in one run, then spend a lot of time finding the point where things go wrong.
+ 3
While using any local variable(except looping variable) for small purpose we usually do not take care to write the description of that local variable.