class Foo {
const int x;
protected:
Foo(int f);
~Foo();
};
Foo f;
Referring to the sample code above, why will the class
declaration not compile?
a) The variable x is const.
b) The destructor is protected.
c) The destructor is not public.
d) The constructor is protected.
e) There is no default constructor.
Answer Posted / gopinath das
a,b,c,d
Is This Answer Correct ? | 1 Yes | 4 No |
Post New Answer View All Answers
Is c++ fully object oriented?
Can we declare a base-class destructor as virtual?
how to connect with oracle 9i with server in socket program in c/c++
What is :: operator in c++?
Does c++ have foreach?
What is the difference between the indirection operator and the address of oper-ator?
what is oops and list its features in c++?
Can you explicitly call a destructor on a local variable?
What are arrays c++?
What is increment operator in c++?
Why c++ is not a pure oop language?
What is the full form of dos?
Does dev c++ support c++ 11?
What is the output of the following program? Why?
List the features of oops in c++?