#include using namespace std; using ll = long long; constexpr char newl = '\n'; int main() { cin.tie(nullptr); ios::sync_with_stdio(false); int n, m; cin >> n >> m; ll ct = 0; int cp = 0; bool ans = true; for (int i = 0; i < m; i++) { ll t; int p; cin >> t >> p; if (t - ct < abs(p - cp)) { ans = false; break; } ct = t; cp = p; } cout << (ans ? "Yes" : "No") << newl; return 0; }