#include using namespace std; using ll = long long; int main() { ios::sync_with_stdio(0); cin.tie(0); ll n, m; cin >> n >> m; ll pos = 0, time = 0; while (m--) { ll t, p; cin >> t >> p; ll dx = abs(p - pos); ll dt = t - time; if (dx <= dt) { pos = p; time = t; } else { cout << "No" << '\n'; return 0; } } cout << "Yes" << '\n'; }