import java.util.*;
class Solution {
public int timeToInteger(String time, boolean isEnd) {
int res = Integer.parseInt(time.substring(0,2)) * 60 + Integer.parseInt(time.substring(3,5));
if(isEnd)
res += 9;
return res;
}
public int solution(String[][] book_time) {
int answer = 0;
int[] rooms = new int[1449];
for(int i = 0; i < book_time.length; i++) {
int staT = timeToInteger(book_time[i][0], false);
int endT = timeToInteger(book_time[i][1], true);
for(int j = staT; j <= endT; rooms[j++]++);
}
for(int i = 0; i < rooms.length; i++) {
if(answer < rooms[i])
answer = rooms[i];
}
return answer;
}
}