Discussion :: Functions - C++
-
What will be the output of the following program?
#include class Freshergate { public: int x, y; Freshergate(int xx = 10, int yy = 20) { x = xx; y = yy; } void Exchange(int *, int *); }; int main() { Freshergate objA(30, 40); Freshergate objB(50); objA.Exchange(&objA.x, &objB.y); cout" " return 0; } void Fresherate::Exchange(int *x, int *y) { int t; t = *x; *x = *y; *y = t ; }
Answer : Option C
Explanation :
No answer description available for this question.
Be The First To Comment

Whatsapp
Facebook