What is the purpose of commenting and how should it be done?
Comments are provided in a program to put information about the logical and reasoning steps based on which the code is implemented. Normally a single line is commented using double slash (//) and a block of lines are commented using the combination of asteric like (/* */). Comments are very important so as to know what was the logic behind the working of code or any other useful information that to be considered while reworking on code.