-2

It seems these two are identical. Does one improve performance over the other for read only variables?

const ant;
final ant;
Stephen D
  • 2,188
  • 3
  • 23
  • 38

1 Answers1

6

const (and goto) is never used. It's just a reserved keyword in Java.

Note that when using const (or goto) the code doesn't even compile.

More info:

Community
  • 1
  • 1
Konstantin Yovkov
  • 60,548
  • 8
  • 97
  • 143