I am new to java and I am having a problem with checking if a time falls/fits into a space of time, ie 10:00-10:30.
The idea is to find out if the time is between 10:00 and 10:30
below is my code:
LocalDateTime timecheck = LocalDate.now().atTime(10, 29);
if(timecheck.getHour() == 10 &&(timecheck.getMinute() <= 30 && timecheck.getMinute() >= 0))
{
//do something
}
Is there is a way to do this simpler.