You are given limits, each with three positive integers
.
Computes the minimal size of a set of integers which has at least
common elements with interval
, for each
.
The first line contains a integers
(
).
The next
lines contains three integers
(
).
It is guaranteed that
, for each
.
Print the number of the minimal size of set.