1 package com.twister; 2 class MyData{ 3 String author = com.twister.Constants.AUTHOR; 4 //lot of other stuff comes hereā€¦ 5 6 public static void main(String[] args) { 7 MyData mydata = new MyData(); 8 System.out.println(mydata.author); 9 } 10 } 11 12 package com.twister; 13 class Constants{ 14 public static final String AUTHOR = "SAM"; //Me of course 15 16 }