can we create object for static class in java
Answer Posted / sandeep
an outer class cannot be static.it can only be declared as
pubic,abstract or final OR a combination..
an inner static class behaves just like a normal static member..
n yes v can creat an object of inner static class as....
Outer.Inner obj=new Outer.Inner();
Is This Answer Correct ? | 38 Yes | 4 No |
Post New Answer View All Answers
What are the main uses of java?
What is static block?
What is lambda programming?
What is a map? What are the implementations of map?
Explain the difference between abstract classes and interfaces in java?
Where is java located?
Which collection allows duplicate values in java?
What is the purpose of main function in java?
What is += mean in java?
What is array initialization in java?
Difference difference paint() and paintcomponent()?
What does it mean that a class or member is final?
How does predicate work in java?
What is the role of garbage collector in java?
What is a jit compiler?