| Do Java support global variable if yes or no give reasons?
My answer is No as Java doesnot support global variables. Below are the two main reasons why this is not supporting global variables.
(1)Global variables will create a collisions in the namespace.
(2)And we use global variable then this will break the referential transparency. | | |