fork download
  1. #include <bits/stdc++.h>
  2. using namespace std;
  3.  
  4. using ll = long long;
  5.  
  6. void solve() {
  7. ll x, y;
  8. cin >> x >> y;
  9. if (x - y != 1) {
  10. cout << "YES" << endl;
  11. } else cout << "NO" << endl;
  12. }
  13.  
  14. int main() {
  15. int t;
  16. cin >> t;
  17. while (t--) solve();
  18. }
Success #stdin #stdout 0s 5280KB
stdin
4
100 98
42 32
1000000000000000000 1
41 40
stdout
YES
YES
YES
NO