A van drives one fixed route serving n trips. Trip i carries p[i] passengers who board at time b[i] and alight at time a[i], with b[i] < a[i]. Passengers of a trip occupy seats during the half-open interval [b[i], a[i]) — riders who alight at a given time free their seats before anyone boarding at that same time needs them.
Find the minimum seat capacity so that at no instant does the number of seated passengers exceed the capacity.
Input format
Line 1: an integer n.
Next n lines: three integers p, b, a — passenger count, board time, alight time.
Output format
A single integer: the minimum required seat capacity.
Constraints
- 1 ≤ n ≤ 100000
- 1 ≤ p[i] ≤ 1000000
- 0 ≤ b[i] < a[i] ≤ 1000000000