/* This is pseudo-code showing an example of a generic function definition */ /* Function Interface Comment promotes good style. It includes the folowing. precondition: a condition assumed to be true before a function call. postcondition: a condition assumed to be true after a function executes. */ type function_name (type(s) and name(s)) { /* local variable declarations */ /* C statements executed when function is called */ /* only if there is one, type of result must match function type */ return (result); } int main( void ) { /* if function returns a value of "type", before this value can be assigned to a variable var, the variable should be declared accordingly */ type var; /* some code */ /* value of the actual argument k is passed to call a function */ function_name(k); /* if function returns a result, it can be assigned to a variable */ var = function_name(k); /* some other code */ return (0); }