from structures import run_operations

class OverlapCalendar:
    def __init__(self):
        self.changes = {}

    def book(self, start, end):
        self.changes[start] = self.changes.get(start, 0) + 1
        self.changes[end] = self.changes.get(end, 0) - 1
        active = peak = 0
        for time in sorted(self.changes):
            active += self.changes[time]
            peak = max(peak, active)
        return peak
