#include<bits/stdc++.h>
using namespace std;

typedef long long ll;
typedef pair<ll,ll>ii;
#define X first
#define Y second
#define pb push_back
#define FOR(i,a,b) for(ll i=a;i<=b;i++)
#define FORD(i,a,b) for(ll i=a;i>=b;i--)
#define all(a) (a).begin(),(a).end()
#define uni(a) (a).resize(unique(all(a)) - (a).begin())
const ll mod = 1e9+7;
const ll maxN = 1e6+5;
const ll N = 1e6;

ll A,B,t;

void solve() {
	cin >> A >> B >> t;
	
	double tmp = (double)(A+B) / 2;
	
	if (tmp >= t) {
		cout << 2 << endl;
		return;
	}
	
	double cnt = (double)(t - A) / (tmp - t);
	ll c1 = floor(cnt);
	if (c1 %2 ==1) c1--;
	ll c2 = c1 + 2;
	
	double res1 = (c1/2.0 * (A+B) + A) / (c1+1.0);
	double res2 = (c2/2.0 * (A+B) + A) / (c2+1.0);
//	cout << c1 << " " << c2 << endl;
//	cout << res1 << " " << res2 << endl;
	if (abs(res1 - t) <= abs(res2-t)) cout << c1 + 1 << endl;
	else cout << c2 + 1 << endl;
	
	
}

int main() {
	//freopen("input.txt", "r", stdin);
	//freopen("output.txt", "w", stdout);
	ios_base::sync_with_stdio(0);
	ll T;
	cin >> T;
	while (T--) {
		solve();
	}
	return 0;
}



