What is the output of this prog. ?


struct A { A(){ cout << \"A\"; } };
struct B { B(){ cout << \"B\"; } };
struct C { C(){ cout << \"C\"; } };
struct D { D(){ cout << \"D\"; } };
struct E : D { E(){ cout << \"E\"; } };
struct F : A, B
{
C c;
D d;
E e;
F() : B(), A(),d(),c(),e() { cout << \"F\"; }
};

Answer Posted / amit prakash

der's no main function so it cant run...

Is This Answer Correct ?    3 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

which of the following is not an secondary constant a) array b) real c) union

1249


Why would you use pointers in c++?

618


What is a namespace in c++?

592


What are c++ data types?

634


Why was c++ created?

540






What are the types of array in c++?

610


Explain what data encapsulation is in c++?

566


What is function prototyping?

614


How is computer programming useful in real life?

588


What do you mean by vtable and vptr in c++?

619


What are the advantages of using typedef in a program?

630


What is the use of ::(scope resolution operator)?

642


What language does google use?

582


What is the role of static keyword for a class member variable?

619


Can a program run without main function?

611