Given n line segments on the number line, where the i-th segment starts at li and ends at ri. Segment j is said to be within segment i if li≤lj≤rj≤ri. For each line segment, count the number of line segments it is contained within (excluding itself).
### Input
- The first line contains an integer n.
- The next n lines, each line contains two integers li and ri.
### Output
- Print n integers, where the i-th integer represents the number of line segments segment i is contained within.
### Constraints
- 1≤n≤105.
- 1≤li≤ri≤105.
### Example
Input
3152314
Output
021