#include <bits/stdc++.h>
using namespace std;
bool equal(double a, double b) { return abs(a - b) < 1e-13; }
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  int ntest;
  cin >> ntest;
  while (ntest--) {
    long long c, h, x, y, t, ans = 2;
    cin >> h >> c >> t;
    long double minDif = abs((long double)(h + c) / 2 - t);
    x = double(t - h) / (h + c - 2 * t);
    y = (x <= 0 ? 0 : x) + 10;
    for (long long i = max(0LL, x - 10); i <= y; i++) {
      long double dif = abs((long double)(i * (h + c) + h) / (2 * i + 1) - t);
      if (minDif >= dif) {
        long long cup = i * 2 + 1;
        if (minDif == dif)
          ans = min(ans, cup);
        else
          ans = cup;
        minDif = dif;
      }
    }
    cout << ans << "\n";
  }
  return 0;
}
