Why Static variable required in java?For ex,class A
{
static int a;
int b;
}
Why static is required?
Answer Posted / vaishnavi
To answer Soumya's question, instance variables are declared at class level, but the instance variables still belong to an instance/object. But static variables belong to a class.
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What is the difference between replace and replace all?
how to deploy apache tomcat server to weblogic server in java
What are the benefits of operations?
What is a method in java?
what is heap memory?
what is encapsulation in java? Explain
How to perform bubble sort in java?
What do you mean by chromounits in java8?
what is the swingutilities.invokelater(runnable) method for? : Java thread
Is java an open source?
What is binary search in java?
Justify your answer that you can't define a method inside another method in java, if you can then how?
What is connection class in java?
What 5 doubled?
Explain importance of inheritance in java?