can we make a class static without using static keyword?
Answer Posted / mamta subramanian
We cannot declare any outer class as static. There would a
compiler error if we do so.
But if it is an inner class we can declare it as static.
and it act as a static object of outer class.
Is This Answer Correct ? | 8 Yes | 2 No |
Post New Answer View All Answers
Why do we use polymorphism?
How is polymorphism achieved?
What is variable example?
Can we override main method?
What are the three parts of a simple empty class?
Why is it so that we can have virtual constructors but we cannot have virtual destructors?
What is the difference between procedural programming and oops?
class type to basic type conversion
What is encapsulation in simple terms?
What are the 3 principles of oop?
What is ambiguity in inheritance?
Give an example where we have to specifically use C programming language and C++ programming language cannot be used?
Why do we use class in oops?
what is the sylabus for priliminaries?
What is multilevel inheritance?