Vidyalelo
C++ Programming · Q142

Functions and Procedures in C++

Programming · C++ Programming · question 142

Q142

What will be the output of the following C++ code? #include using namespace std; void square (int *x) *x = (*x + 1) * (*x); int main ( ) int num = 10; square(&num); cout << num; return 0; a) 100

A.
100
B.
compile time error
C.
144
D.
110
Answer

Answer: Option D

Solution

Answer: Option D
No explanation is given for this question Let's Discuss on Board