Hi,
I have always known and believed that a variable declared as local in a class can be accessed only within the class and not outside.
Also a variable declared as a static is shared with the class instances and no separate copy for instance is made…
But during a recent interview i had attended, the interviewer said a local variable can be accessed from a extended class by declaring it as both static and local in the base class… I am confused now…
Can i get a clear consensus on this please???