csu 1458: Booking (开的房间数量)

2014-11-24 13:25:48 · 作者: · 浏览: 43

1458: Booking

Time Limit: 3 Sec Memory Limit: 128 MB
Submit: 116 Solved: 27
[Submit][Status][Web Board]

Description

\

Input

\

Output

\

Sample Input

4
2 120
1 2013-07-01 15:59 2013-07-08 16:30
2 2013-07-08 17:30 2013-07-15 12:00
3 60
65 2013-07-08 14:30 2013-07-08 16:00
32 2013-07-01 16:00 2013-07-15 12:00
91 2013-07-01 16:00 2013-07-08 15:00
2 360
a7 2016-02-21 14:00 2016-02-28 21:00
xx 2016-03-01 01:00 2016-03-02 12:57
2 60
a9 2016-02-21 14:00 2016-02-28 11:00
a8 2016-02-28 12:00 2016-03-11 21:00

Sample Output

2
3
1
1
题意:开房的预定时间和离开时间,下一个要重新开一间那么这次预定时间必须要在前面开房的离开时+打扫时间之内。
#include
   
    
#include
    
      #include
     
       using namespace std; typedef struct nnn { int st; int et; }node; node book[5005]; int cmp(node a,node b) { if(a.st==b.st) return a.et