hi, I need your help and would like to know how and whats the best technique you programmers would use to solve this problem. Ok, this program that IM going to be making has a start and end time reserve.And It will also ask a user to enter a start and end time. Now C++ will try to add it but first it has to check if the user input time will overlap with the reserve time.
for example:
the reserve time is-->lets say,
Reserve time=10:30 to 11:50
so, if the user enters a time between 10:30 and 11:50 C++
should refuse. If User enters 9:30 thru 10:29 then C+ would add.
This is what I was thinking of using to validate,do you think this will work?
if(Input_Hour==Reserve_Hour)
{
if(Input_End_Minute<Reserve_Start_minute)
{ cout<<"OK add";
}
}
else
{ cout<<"NO add";
}