n,m =map(int,input().split()) import collections llist = collections.defaultdict(int) rlist = collections.defaultdict(int) for i in range(m): l,r =map(int,input().split()) llist[l] += 1 rlist[r] += 1 for i in reversed(range(1,n+1)): if i == n: temp = llist[i] print(temp) else: temp += llist[i] temp -= rlist[i+1] print(temp)