What is the output of this C++ program?
#include
using namespace std;
void square (int *x)
{
*x = (*x)++ * (*x);
}
void square (int *x, int *y)
{
*x = (*x) * --(*y);
}
int main ( )
{
int number = 30;
square(&number, &number);
cout << number;
return 0;
}
910
920
870
900
This question is part of this quiz :
C++ Function Overloading and Default Arguments,ISRO CS 2017 - May,C Programming PYQ ISRO QUIZ