Question: QUESTION 8 Can static variables be used for counting instances in Java? In JAVA, you cannot declare a static variable. No , static variables cannot
QUESTION
Can static variables be used for counting instances in Java?
In JAVA, you cannot declare a static variable.
No static variables cannot be used for counting instances.
Yes, static variables are commonly used for this purpose.
Static variables are not related to instance counting.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
