having trouble using LocalDate, error says it can't be resolved to a type

I’m a beginner programmer and I have just started learning about topics related to date and time. The code that my teacher writes works just fine on his computer, but in mine I can’t even run it. This is the code in question: package application; import java.time.LocalDate; import java.time.LocalDateTime; public class Program { public static… Read More having trouble using LocalDate, error says it can't be resolved to a type

Clean way to check if a LocalDateTime is in a given range (working hours of some business)

I need to check if a given LocalDateTime is during the opening hours of a business, which are Monday – Friday, 8:00 – 12:30 and 14:00 – 18:00 Saturday, 8:00 – 14:00 I have the below method to do so, but I find it too cumbersome for such a simple requirement. Is there an eleganter… Read More Clean way to check if a LocalDateTime is in a given range (working hours of some business)