African ChildrenTime limit: 1000 ms | Memory limit: 65535 KB Difficulty: 2 The children who lived in Africa were very dark. Why, then?
First, they are located in the tropics with severe solar radiation.
Second, they don't often bathe. (Perennial lack of water, how to bathe.) )
Now, in an African tribe, they have only one place to bathe, and the bath time is short, and there is wood in the moment. (This is also no way, lack of water ah.) )
Each child has a period of time to bathe. And, they can be washed together (whether you are a boy or a girl).
So, what time to bathe, who should come to wash, who decided. That must be their great "bath" God. "Bath" God has a timetable that records the children of the tribe, when the time can take a bath. Now, "bath" God wants to ask you, in one day, he needs to open and shut down how many times a shower faucet. Because, opening and closing a faucet once is very laborious, even, this is also instantaneous completes.
Enter multiple sets of data
The first line is a 0<n<=100.
Next n rows, one time period per line. H1H1:M1M1-H2H2:M2M2,24-hour system.
Ensure that the time period is within a day. However, there is no guarantee that h1h1:m1m1 before the h2h2:m2m2. The output topic describes how many taps the "shower" God needs to turn on and off at least once. Sample input
1
00:12-12:12
2
00:12-12:12
14:00-12:00
Sample output
1
1
Tip Ps: Turn on and off for once
Similar to NYOJ-891, range.
#include <iostream> 02. #include <algorithm> 03. using namespace Std; struct node 05. {h1,h2,m1,m2 int; }B[110]; -BOOL CMP (node A1,node a2) 09. {a1.h2<a2.h2; return 11.} 12. int main () 13. {14.