#include <bits/stdc++.h>
#pragma comment(linker, "/stack:200000000")
#pragma GCC optimize("unroll-loops")
#pragma GCC optimize("O3")
using namespace std::chrono;
using namespace std;
long long mul(long long a, long long b, long long m = 1000000007) {
  long long res = 0;
  a = a % m;
  while (b > 0) {
    if (b % 2 == 1) res = (res + a) % m;
    a = (a * 2) % m;
    b /= 2;
  }
  return res % m;
}
long long expMod(long long a, long long b, long long m = 1000000007) {
  long long x = 1, y = a;
  while (b) {
    if (b % 2 == 1) {
      x = mul(x, y, m);
    }
    y = mul(y, y, m);
    b = b / 2;
  }
  return x;
}
long long pw(long long a, long long b) {
  long long c = 1, m = a;
  while (b) {
    if (b & 1) c = (c * m);
    m = (m * m);
    b /= 2;
  }
  return c;
}
long long pwmd(long long a, long long b) {
  long long c = 1, m = a;
  while (b) {
    if (b & 1) c = (c * m) % 1000000007;
    m = (m * m) % 1000000007;
    b /= 2;
  }
  return c;
}
long long mmi(long long a) {
  long long inverse = pwmd(a, 1000000007 - 2);
  return inverse;
}
long long nCrModp(long long n, long long r) {
  long long C[r + 1];
  memset(C, 0, sizeof(C));
  C[0] = 1;
  for (long long i = 1; i < n + 1; ++i)
    for (long long j = min(i, r); j >= 1; --j)
      C[j] = (C[j] + C[j - 1]) % 1000000007;
  return C[r];
}
int my_log(long long n, int b) {
  long long i = 1;
  int ans = 0;
  while (1) {
    if (i > n) {
      ans--;
      break;
    }
    if (i == n) break;
    i *= b;
    ans++;
  }
  return ans;
}
inline bool kthbit(long long n, int k) { return (n >> k) & 1; }
inline long long setkthbit(long long n, int k) { return n | (1ll << k); }
inline long long unsetkthbit(long long n, int k) { return n & ~(1ll << k); }
inline long long flipkthbit(long long n, int k) { return n ^ (1ll << k); }
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  ;
  long double T, c, h, tmp;
  cin >> T;
  while (T--) {
    cin >> h >> c >> tmp;
    if (h <= tmp) {
      cout << 1 << "\n";
      continue;
    }
    long double mid = (h + c) / 2;
    if (tmp <= mid) {
      cout << 2 << "\n";
      continue;
    }
    long double prev = 1e18;
    long double z = abs(tmp - ((h + c) / 2));
    prev = min(prev, z);
    long long y = floor((tmp - c) / (2 * tmp - h - c));
    long double r = (y * h + (y - 1) * c) / (2 * y - 1);
    r = abs(r - tmp);
    prev = min(r, prev);
    long double s = ((y + 1) * h + y * c) / (2 * (y + 1) - 1);
    s = abs(s - tmp);
    prev = min(s, prev);
    if (prev == z)
      cout << 2 << "\n";
    else if (prev == r)
      cout << 2 * y - 1 << "\n";
    else
      cout << 2 * (y + 1) - 1 << "\n";
  }
}
