Java tutorial
import java.util.GregorianCalendar; import java.util.SimpleTimeZone; public class Main { public static void main(String args[]) { SimpleTimeZone stobj = new SimpleTimeZone(720, "US"); // get offset int offset = stobj.getOffset(GregorianCalendar.AD, 2000, 10, 2, 4, 5000); // check offset value System.out.println("Offset is : " + offset); } }