Interval tree with added dimension of subset matching?
问题 This is an algorithmic question about a somewhat complex problem. The foundation is this: A scheduling system based on available slots and reserved slots . Slots have certain criteria, let's call them tags . A reservation is matched to an available slot by those tags, if the available slot's tag set is a superset of the reserved slot. As a concrete example, take this scenario: 11:00 12:00 13:00 +--------+ | A, B | +--------+ +--------+ | C, D | +--------+ Between the times of 11:00 to 12:30