0
Can someone explain this program to you?
class A { public: A(){cout<<"a";} A(const A&x){cout<<"b";} } int main() { A x; A y(x); }
3 Answers
+ 2
I dunno why you tagged it C, this is C++.
It's a class with an overloaded constructor and (very bad) implicit destructor.
The main function creates object x of type A, then object y of type A, passing x as it does so in the latter case.
+ 4
No prob, I'm used to language barriers, printos/typos, etc.
0
sorry, that was a huge mistake.
BTW, thanks for the answer.
Also, there is one more mistake in the question itself. I've written you instead of me.đ



