From science to arts, IDNLearn.com has the answers to all your questions. Our community provides timely and precise responses to help you understand and solve any issue you face.
Answer:
d. result = cube(4);
Explanation:
Given
Prototype: int cube(int num);
Function: int cube(int num) { return num * num * num; }
Required
The statement to get the cube of 4, saved in result
To do this, we have to call the cube function as follows:
cube(4);
To get the result of the above in variable result, we simply assign cube(4) to result.
So, we have:
result = cube(4);