problems: https://codeforces.com/contest/1761
A
a + b + 2 <= n
是为了确保能够至少往前移一位
官方题解: https://codeforces.com/blog/entry/109256
中文私货题解: https://www.luogu.com.cn/blog/111055/ezec-r13-chinese-editorial
最后上代码
#include <bits/stdc++.h>
using namespace std;
int main()
{
int tt;
cin >> tt;
while (tt--) {
int n, a, b;
cin >> n >> a >> b;
if (a == n && b == n) {
cout << "Yes" << '\n';
continue;
}
if (a + b < n - 1) {
cout << "Yes" << '\n';
continue;
}
cout << "No" << '\n';
}
return 0;
}