Preconditions and Postconditions
One good way to write a function prototype comment is to break it down into two kinds of information called a precondition and postcondition
The precondition states what is assumed to be true when the function is called and the function should not be expected to perform correctly unless the precondition holds
The postcondition described the effect of the function call, that is, the postcondition tells what will be true after the function call is executed in a situation in which the precondition holds
For a function that returns a value, the postcondition will describe the value returned by the function
For a function that changes the value of some argument variables, the postcondition will describe all the changes made to the values of the arguments