Range Module
Design a relay coverage tracker that manages half-open intervals [left, right) on the integer line. The tracker starts empty and supports three operations:
addRange(left, right)adds the half-open interval[left, right)to the tracked set, merging overlapping or adjacent intervals.queryRange(left, right)returnstrueif every integer in[left, right)is currently tracked, otherwisefalse.removeRange(left, right)removes the half-open interval[left, right)from the tracked set, splitting existing intervals when necessary.
This is the original Google Range Module problem (LeetCode 715). All intervals are half-open, left < right, and 0 <= left < right <= 10^9. The constructor RangeModule() creates an empty tracker. Operations are relayed through a deterministic functional dispatch solve(operations, args) that returns an array of results where addRange and removeRange produce null and queryRange produces a boolean, with the first RangeModule construction also producing null.
Range Module
Design a relay coverage tracker that manages half-open intervals `[left, right)` on the integer line. The tracker starts empty and supports three operations: