So I actually no longer see your problem.
So now let's assume that somebody is supposed to enter this in a terminal program; you don't give the details so it's a fair assumption. There are a million different date and time formats, how are you going to cater for that.
After all, what is 09/05/2018? May 9 or Sep 5; for me it's the first. Are you going to tell the user that the format is mm/dd/yyyy and you expect the user to remember that?