Current location - Plastic Surgery and Aesthetics Network - Plastic surgery and medical aesthetics - A) static final int I =100; b)final int I = 1.2; C) final exam 1; D) Which definition of the last character is correct, and explain why.
A) static final int I =100; b)final int I = 1.2; C) final exam 1; D) Which definition of the last character is correct, and explain why.
A. correct

B. mistakes. I is plastic and 1.2 is floating point.

C. mistakes. The type of i is undetermined. It is necessary to give an example such as int, stringing, char and so on.

D. Uncertain, seemingly wrong, the final modifier attribute is that an initial value must be assigned and cannot be changed.

But there is no code behind you. In the constructor, you can also assign an initial value (before creating the object).

Well, think it's wrong. The point is that you understand.