Gaurangkumar Khalasi wrote:What is the difference between the following
1). public final int va=9; --- Constant Variable
In above scenario final means you can't reinitialize it and va is a instance variable but we call it constant variable because of this behavior.
Gaurangkumar Khalasi wrote:2). public static int va=9; --- Static Variable or Class Variable
In above scenario static means va is a class variable and you can reinitialize it .
Gaurangkumar Khalasi wrote:3). public static final int va=9; --- ???
Then in above scenario static and final means ?? you can't reinitialize va becauseof final and becauseof static va is a class variable .