1.

Why There Are No Global Variables In Java?

Answer»

GLOBAL variables are globally accessible. Java does not support globally accessible variables DUE to following reasons:
• The global variables breaks the referential transparency.
• Global variables CREATES COLLISIONS in namespace.

Global variables are globally accessible. Java does not support globally accessible variables due to following reasons:
• The global variables breaks the referential transparency.
• Global variables creates collisions in namespace.



Discussion

No Comment Found