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 / guest
a
Is This Answer Correct ? | 2 Yes | 4 No |
Post New Answer View All Answers
What is the best c++ ide?
Describe private, protected and public – the differences and give examples.
How do pointers work?
Does there exist any other function which can be used to convert an integer or a float to a string?
What is the use of seekg in c++?
Is there finally in c++?
How is c++ used in the real world?
Is map sorted c++?
Write about the members that a derived class can add?
What is the difference between an external iterator and an internal iterator?
Perform addition, multiplication, subtraction of 2-D array using Operator Overloading.
What is srand c++?
Explain linear search.
What is meant by iomanip in c++?
Refer to a name of class or function that is defined within a namespace?