What is size of a object of following class?
class Foo
{
public:
void foo(){}
}
Answer Posted / jitendra varshney
The size of the object here will be 1. Because by default,
if no variable is declared in the class the size of object is 1.
this is due to fact that when two or more object of the
class is defined then they would have the different
addresses. But if size would have been zero then it might be
possible that two or more object can have the same address.
| Is This Answer Correct ? | 1 Yes | 1 No |
Post New Answer View All Answers
What character terminates all character array strings a) b) . c) END
What are c++ redistributables?
What is a unnitialised pointer?
Can you please explain the difference between using macro and inline functions?
What return value must conversion operators have in their declaration?
Can you overload the operator+ for short integers?
What does 7/9*9 equal ? a) 1 b) 0.08642 c) 0
What is meant by a delegate?
what is Member Functions in Classes?
What is late binding c++?
What do you mean by funtion prototype?
What is the insertion operator and what does it do?
What is meant by entry controlled loop?
Specify some guidelines that should be followed while overloading operators?
What is called array?