Read it again, the problem statement mentions that each schedule is for a single day. It wouldn't make sense for it to not be sorted. I modified my AC code to produce a RE if any train schedule wasn't for a single day or not sorted in increasing time. I resubmitted and it still got AC.
Check input and AC output for thousands of problems on uDebug!
Spent 6 hours fixing bugs, the final bug was misreading following:
After each scenario print a blank line.
Lots of problems here on UVA ask to print blank line between testcases, so this is what my template did by default and I didn't even think about double checking that. On a good side after all optimizations and refactorizations I've got 0.036 running time.