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