import java.time.*;
public class OnePlusOne {
public static void main(
String... nums) {
LocalDate time = LocalDate.of(1, 11);
while (time.getHour() < 1) {
time.plusHours(1);
System.out.println("in loop");
}
}
}
76. E. The LocalDate class is only for day/month/year values. It does not support time, so getHour and plusHours() do not compile, making Option E the answer.
It does not explain the fact that LocalDate.of(1, 11); does not compile because it should be LocalDate.of(1,11,1); It needs 3 arguments(int,int,int).Compile error if it has less than 3.