0
Hi anyone can explain What's return's operation here?
Int sqr (x) { Result=x*x; Return x; }
1 Resposta
+ 2
It will return the value of x*x.. BTW code is logically wrong, coz this will return the value you passed as parameter.. It should be like ‘return result;' .. Return keyword passes the value or can be used without value while using void data type, when return is executed the control of program jumps back to the point from where the particular function was called and starts executing next line of that code..