Answer Posted / aravinda reddy
No we can't declare a static variable in a method or static
method, static variables are class level variables. Static
means one per class as per OO rules and method level
variables scope is with in the method. So if java allows
static variable inside a method, static concept is useless.
| Is This Answer Correct ? | 8 Yes | 0 No |
Post New Answer View All Answers
How to disable caching on back button of the browser?
Name few java 8 annotations ?
What is struts in java?
What do you mean by stream pipelining in java 8?
What is a return in java?
What is keyword in oop?
Is java an ide?
What is command line used for?
Can I import same package/class twice?
What does mean in regex?
What do you understand by copy constructor in java?
Which is best ide for java?
What is the formula to calculate percentage?
What is primitive data type in java?
When is the arraystoreexception thrown?