Java tutorial
import java.time.OffsetDateTime; import java.time.temporal.ChronoUnit; public class Main { public static void main(String[] args) { OffsetDateTime o = OffsetDateTime.now(); OffsetDateTime d = o.minus(20, ChronoUnit.HOURS); System.out.println(d); } }