toshit kolhe wrote:i think think that the initialised int x = 24; is an instance variable and cannot be called by the static method void go().
That's correct, but as Bear says, you have two variables called x, so have you considered it might be the other x that is being referenced in the go method.