Let's call an integer array a_1, a_2, ..., a_n good if a_i ≠ i for each i.

Let F(a) be the number of pairs (i, j) (1 ≤ i < j ≤ n) such that a_i + a_j = i + j.

Let's say that an array a_1, a_2, ..., a_n is excellent if: 

  * a is good; 
  * l ≤ a_i ≤ r for each i; 
  * F(a) is the maximum possible among all good arrays of size n. 



Given n, l and r, calculate the number of excellent arrays modulo 10^9 + 7.

Input

The first line contains a single integer t (1 ≤ t ≤ 1000) — the number of test cases. 

The first and only line of each test case contains three integers n, l, and r (2 ≤ n ≤ 2 ⋅ 10^5; -10^9 ≤ l ≤ 1; n ≤ r ≤ 10^9).

It's guaranteed that the sum of n doesn't exceed 2 ⋅ 10^5.

Output

For each test case, print the number of excellent arrays modulo 10^9 + 7.

Example

Input


4
3 0 3
4 -3 5
42 -33 55
69 -42 146


Output


4
10
143922563
698570404

Note

In the first test case, it can be proven that the maximum F(a) among all good arrays a is equal to 2. The excellent arrays are: 

  1. [2, 1, 2]; 
  2. [0, 3, 2]; 
  3. [2, 3, 2]; 
  4. [3, 0, 1]. 
#include <bits/stdc++.h>
#define rep(i, a, b) for(int i = a; i < b; i ++)
#define mx 500005
#define LL long long
#define MOD 1000000007
using namespace std;

LL n, l, r;
LL fac[mx], inv[mx], rv[mx];

void init() {
	fac[0] = inv[0] = fac[1] = inv[1] = rv[1] = 1;
	for (int i=2; i < mx; i++) {
		rv[i] = (LL)rv[MOD % i] * (MOD - MOD / i) % MOD;
		fac[i] = ((LL)fac[i-1] * i) % MOD;
		inv[i] = (LL)inv[i - 1] * rv[i] % MOD;
	}
}

LL C(int n, int k) {
	return (fac[n] * inv[k] % MOD) * inv[n - k] % MOD;
}

int main() {
#ifndef ONLINE_JUDGE
	freopen("in.txt", "r", stdin);
//	freopen("out.txt", "w", stdout);
#endif

	cin.tie(0); cout.tie(0);
	ios::sync_with_stdio(0);

	int tc; cin >> tc;
	init();
	while(tc --){
		cin >> n >> l >> r;
		LL lim = min(1ll - l, r - n);
		LL rlt = 0ll;
		rlt = lim * C(n, n / 2) % MOD; 	
		if (n % 2) rlt = (rlt + lim * C(n, (n + 1) / 2) % MOD) % MOD;
		for (LL i = lim + 1; i <= max(r - 1, n - l); i ++) {
//			cerr << rlt << ' ';
			LL rm = max(l + i - 1, 0ll) + max(n + i - r, 0ll);
			if (rm > n) break;
			if ((n + 1) / 2 >= max(l + i - 1, 0ll) && (n + 1) / 2 >= max(n + i - r, 0ll)) rlt = (rlt + C(n - rm, n / 2 - max(l + i - 1, 0ll))) % MOD;
			if (n % 2 && (n + 1) / 2 >= max(l + i - 1, 0ll) && (n + 1) / 2 >= max(n + i - r, 0ll)) rlt = (rlt + C(n - rm, (n + 1) / 2 - max(l + i - 1, 0ll))) % MOD;
		}
	
		cout << rlt << endl;
	}

	return 0;
}

