what is different between static and non static methods ,using
example
Answer Posted / guest
Static:
we dont have to create instance of an object
Staic methods cannot access nonstatic methods.
same with variable static variables cannot access static
variables
Non-Static:
we have to create instance of an object
nonStaic methos canaccess nonstatic methods.
same with variable nonstatic variables can access static
variables
Is This Answer Correct ? | 0 Yes | 1 No |
Post New Answer View All Answers
Can we have multiple catch block for a try block?
What does it mean to be immutable?
How many digits is int32?
What is codebase?
What is the difference between a break statement and a continue statement?
What does isempty () do in java?
Can we override constructors in java?
List any five features of java?
How to do encapsulation in java?
What is keyword in oop?
What are the new features in java 8? Explain
Difference between stack and queue?
Which is better stringbuffer or stringbuilder?
What is the basic difference between string and stringbuffer object?
Can we increase array size dynamically in java?