Question: 1. In this general syntax of a function: type name ( parameter1, parameter2, ...) { statements } what is type? 2. For the following function
1. In this general syntax of a function:
type name ( parameter1, parameter2, ...) { statements }
what is "type"?
2. For the following function header answer the 3 questions below
bool CheckNumber (float a)
- what is CheckNumber? - Does the function return anything? If yes give an example of value returned by this function. - show a possible call of this function
3. Where do all functions prototypes go?
4.In the following program make a change such that you don't need the variable z.
// function example #include using namespace std; int addition (int a, int b) { int r; r=a+b; return r; } int main () { int x, y, z; z = addition (5,3); cout << "The result is " << z; } Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
