close-red

ECO403 - Macroeconomics

Question(s) similar to the following:

Consider the following code segment. What will be the output of the following code segment?

class class1{
 public: class class2{
 public: class2(){
  cout << "Calling default constructor of class2 " ;
 }
 };
 class1(){
  cout << "Calling default constructor of class1 " ;
 }
};
main(){
 class1::class2 obj1;
 class1 obj2;
}

Question 1:

Consider the following code segment. What will be the output of the following code segment?

class class1{
 public: class class2{
 public: class2(){
  cout << "Calling default constructor of class2 " ;
 }
 };
 class1(){
  cout << "Calling default constructor of class1 " ;
 }
};
main(){
 class1::class2 obj1;
 class1 obj2;
}

Answer: Suggest Edit

Provide solution with reference to earn 1000 credits

Similar Questions:

Question 2:

Consider the following code segment. What will be the output of the following code segment?

class class1{
 public: class class2{
 public: class2(){
  cout << "Calling default constructor of class2 " ;
 }
 };
 class1(){
  cout << "Calling default constructor of class1 " ;
 }
};
main(){
 class1::class2 obj1;
 class1 obj2;
}

Answer: Suggest Edit

Provide solution with reference to earn 1000 credits
Past Papers of ECO403 - Macroeconomics
Sponsored

Attach VULMS for better learning experience!
Attach VULMS Account

Our VULMS adds features of MDBs and lets your populate VU subjects automatically.

Tajweed Classes (Learn Quran with Tajweed)
Learn Holy Quran with Tajweed

Try our 3 days free demo now! Online online holy quran tajweed classes are useful to learn reading holy quran with tajweed.

Gegasoft POS/CRM Software
Gegasoft Point of Sale/Customer Relationship Managemnet Software

Gegasoft Point of Sale/Customer Relationship Management software is an accounting software to fulfill your business needs.

Sponsored

?