In MonTech, there are collaborative projects, each uniquely identified from 1 to . Today, coders assemble, numbered from 1 to . Due to the multitude of projects, each coder will only contribute to a specific range of projects.
The -th coder will contribute to projects numbered -th, -th, ..., -th project.
You are given a task. For each coder, what is the number of other coders they are collaborating with?
Note: Two coders are collaborating if and only if, they contribute to one or more projects with the same id.
Input
The first line contains two integers, and – the number of coders and projects respectively.
The next lines contain two integers each , – the numbers of the projects that the -th coder is contributing to.
Output
lines, where the -th line contains the number of other coders that are collaboriting with the -th coder.
Constraints
Example 1
Input
5 5
4 5
1 3
2 4
1 5
1 1
Output
2
3
3
4
2
Comments