#include <bits/stdc++.h>
using namespace std;
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  int t;
  cin >> t;
  while (t--) {
    double h, c, x;
    cin >> h >> c >> x;
    double lw = (h + c) / 2.0;
    if (x <= lw) {
      cout << 2 << '\n';
      continue;
    }
    int l = -1, r = h;
    int mn = 0;
    double best = 100000000.0;
    while (r - l > 1) {
      double mid = (l + r) / 2;
      double mde = (mid * (h + c) + h) / (2 * mid + 1);
      if (abs(mde - x) < best) {
        best = abs(mde - x);
        mn = mid * 2 + 1;
      } else if (abs(mde - x) == best && mn > mid * 2 + 1) {
        mn = mid * 2 + 1;
      }
      if (mde > x)
        l = mid;
      else
        r = mid;
    }
    cout << mn << '\n';
  }
  return 0;
}
