#include <bits/stdc++.h>
using namespace std;
int main() {
  int T;
  cin >> T;
  while (T--) {
    long long n, s, t;
    cin >> n >> s >> t;
    if (s == t == n) {
      cout << 1 << endl;
    } else if (s > t) {
      cout << (n - t + 1) << endl;
    } else if (s <= t) {
      cout << (n - s + 1) << endl;
    }
  }
  return 0;
}
