Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CPP

return function in cpp

// Multiple return statements often increase complexity.
int max(int a, int b) {
    if (a > b) {
        return a;
    } else {
        return b;
    }
}//end max
Source by www.fredosaurus.com #
 
PREVIOUS NEXT
Tagged: #return #function #cpp
ADD COMMENT
Topic
Name
2+7 =