what is different between static and non static methods ,using
example
Answers were Sorted based on User's Feedback
Answer / siva
we should create object form calling Non static method but
no necessary to create object for calling static method
using class name we call static method
| Is This Answer Correct ? | 0 Yes | 0 No |
Answer / 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 |
wHAT IS DEFAULT SPECIFIER IN JAVA wHAT IS DEFAULT CONSTRUCTOR IN JAVA wHAT IS DEFAULT METHOD IN JAVA
Explain the difference between getAppletInfo and getParameterInfo?
What is a methodologist?
Which collection does not allow duplicates in java?
Why do we use bufferedreader?
Can we create constructor in abstract class ?
What is the common usage of serialization?
What are the two ways in which thread can be created?
Why java uses the concept of the string literal?
Name few java util classes introduced with java 8 ?
What is the nested interface?
Define how can we find the actual size of an object on the heap?