#include <bits/stdc++.h>
using namespace std;
long long h, c;
long double x = 1.0;
long double get(long long moves) {
  long double x = 1.0;
  return c + ((moves) / (2 * moves - 1.0)) * (h * x - c * x);
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  long long n, t, m, y, z, temp;
  cin >> t;
  while (t--) {
    cin >> h >> c >> temp;
    if (2 * temp <= (h + c)) {
      cout << 2 << '\n';
      continue;
    }
    long long lo = 1, hi = 1e15, mid;
    while ((hi - lo) > 1) {
      mid = (hi + lo) / 2;
      if (get(mid) > temp * 1.0) {
        lo = mid;
      } else {
        hi = mid;
      }
    }
    if (abs(get(lo) - x * temp) <= abs(get(hi) - x * temp)) {
      cout << 2 * lo - 1 << '\n';
    } else {
      cout << 2 * hi - 1 << '\n';
    }
  }
  return 0;
}
