A soccer league has $N$ teams, numbered from $1$ to $N$. In this league every pair of distinct teams plays exactly once, so a total of $N(N-1)/2$ matches are played.
In each match, the team that scores more goals wins. Points are awarded as follows:
The league standings are determined solely by the total number of points each team has earned; goal difference is not considered. Teams with the same total share the same rank, and that rank is the highest possible value. In other words, a team's rank equals (the number of teams with strictly more points) $+, 1$.
For example, suppose $4$ teams take part in the league, so $4(4-1)/2 = 6$ matches are played. Suppose the results are as in the table below. In each cell, the number to the left of the hyphen (-) is the score of the team in that row, and the number to the right is the score of the team in that column.
| Team 1 | Team 2 | Team 3 | Team 4 | W | D | L | Pts | |
|---|---|---|---|---|---|---|---|---|
| Team 1 | --- | 0 - 1 | 2 - 1 | 2 - 2 | 1 | 1 | 1 | 4 |
| Team 2 | 1 - 0 | --- | 1 - 1 | 3 - 0 | 2 | 1 | 0 | 7 |
| Team 3 | 1 - 2 | 1 - 1 | --- | 1 - 3 | 0 | 1 | 2 | 1 |
| Team 4 | 2 - 2 | 0 - 3 | 3 - 1 | --- | 1 | 1 | 1 | 4 |
Team 2 has the most points and is ranked $1$st. Team 1 and Team 4 have the next-highest and equal totals, so both are ranked $2$nd. Team 3 has the fewest points and is ranked $4$th.
Given the results of all matches, write a program that computes the rank of each team.
The first line contains the number of teams $N$ ($2 \le N \le 100$).
Each of the next $N(N-1)/2$ lines contains the result of one match as four integers $A$ $B$ $C$ $D$, meaning that in the match between team $A$ and team $B$, team $A$ scored $C$ points and team $B$ scored $D$ points. $A$ and $B$ are always different, and the result of the same match is never given more than once.
Print $N$ lines. The $i$-th line contains the rank of team $i$.