Advertisement
JeffGrigg

FinalVariable

Jul 25th, 2017
269
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 5 0.25 KB | None | 0 0
  1. public class FinalVariable {
  2.  
  3.     static final int a;
  4.  
  5.     static{
  6.         System.out.println(FinalVariable.a);
  7.     }
  8.  
  9.     static{
  10.         a = 10;
  11.     }
  12.  
  13.     public static void main(String[] args) {
  14.         System.out.println(a);
  15.     }
  16. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement