Alexey_Skadorva

Untitled

Mar 31st, 2016
155
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.40 KB | None | 0 0
  1. public class Tasks {
  2.     public static Tasks instance = new Tasks();
  3.     private static final int DELTA = 5;
  4.     private static int BASE = 7;
  5.     private int x;
  6.  
  7.     public Tasks() {
  8.         x = BASE + DELTA;
  9.     }
  10.     public static int getBASE() {
  11.         return BASE;
  12.     }
  13.     public static void main(String[] args) {
  14.         System.out.println(Tasks.instance.x);
  15.     }
  16. }
Advertisement
Add Comment
Please, Sign In to add comment