What is the final blank variable in Java?

A final variable, not initialized at the time of declaration, is known as the final blank variable. We can’t initialize the final blank variable directly. Instead, we have to initialize it by using the class constructor. It is useful in the case when the user has some data which must not be changed by others, for example, PAN Number. Consider the following example:

  1. class Student{
  2. int id;
  3. String name;
  4. final String PAN_CARD_NUMBER;
  5. }