Consider the following function and answer the questions tha

Consider the following function and answer the questions that follows: return x - 2 * y;} Show in the box provided the output of the following line: printf(\"%d\", someFunction(4, 12)); Write in the box provided the value of x that will be printed on the screen in the following code segment? int x; x = someFunction(4, 2) + 6; printf(\"%d\", x);

Solution

4.1.Solution :-


The printf() statement printf(\"%d\",someFunction(4,12)); produces the output as -20.

Explanation:-

When the control comes to printf(\"%d\",someFunction(4,12)); the someFunction(4,12) is called then the control goes to return x-2*y;.

 Consider the following function and answer the questions that follows: return x - 2 * y;} Show in the box provided the output of the following line: printf(\

Get Help Now

Submit a Take Down Notice

Tutor
Tutor: Dr Jack
Most rated tutor on our site