Function Prototype for maximum

Member function maximum’s prototype (Fig. 6.2, line 16) indicates that the function returns an integer value, has the name maximum and requires three integer parameters to perform its task. The function’s first line (Fig. 6.3, line 60) matches the function prototype and indicates that the parameter names are x, y and z. When maximum is called (Fig. 6.3, line 56), the parameter x is initialized with the value of the argument grade1, the parameter y is initialized with the value of the argument grade2 and the parameter z is initialized with the value of the argument grade3. There must be one argument in the function call for each parameter (also called a formal parameter) in the function definition.

Notice that multiple ...

Get C++11 for Programmers, Second Edition now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.