#include using namespace std; using ll = long long; #define rep(i,m,n) for(int i=m; i> N >> K; vector L(K), R(K); rep(i, 0, K){ cin >> L[i] >> R[i]; } vector table(500100, 0); rep(i, 0, K){ table[R[i]] += 1; table[L[i]+1] -= 1; } rep(i, 1, N+1){ table[i] += table[i-1]; } for(int i=N; i>0; --i){ cout << table[i] << endl; } return 0; }