Roy Tang

Programmer, engineer, scientist, critic, gamer, dreamer, and kid-at-heart.

Blog Notes Photos Links Archives About

You can assign it a value that is specific to the object instance, which you can’t do with a static class variable.

Posted by under notes at #java
Also on: stackexchange / 2

Comments

so you mean when i write the class i just declare it as final. and when i have instantiated the class and call a method, the method will assign a value to it which cannot be changed?
I think you need to assign a value in the constructor, otherwise the compiler will throw an error.