import java.time.LocalDate; import java.time.format.DateTimeFormatter; import java.util.Scanner; public class No721_DieTertia { public static void main(String[] args) { Scanner scan = new Scanner(System.in); String value1 = scan.next(); scan.close(); // String value1 = "2018/09/24"; String result = plusTwoDays(value1); System.out.println(result); } public static String plusTwoDays(String value1) { LocalDate date = LocalDate.parse(value1, DateTimeFormatter.ofPattern("yyyy/MM/dd")); String datePlusTwoDays = date.plusDays(2).format(DateTimeFormatter.ofPattern("yyyy/MM/dd")); return datePlusTwoDays; } }