#include <bits/stdc++.h>
using namespace std;
void solve() {
  long long h, c, t;
  cin >> h >> c >> t;
  if ((h + c) / 2 >= t) {
    cout << 2 << '\n';
    return;
  }
  long long a = t - h;
  long long b = h + c - 2 * t;
  long long k = 2 * (a / b) + 1;
  long long val2 =
      abs((k + 2) / 2 * 1ll * c + (k + 3) / 2 * 1ll * h - t * 1ll * (k + 2));
  long long val1 = abs(k / 2 * 1ll * c + (k + 1) / 2 * 1ll * h - t * 1ll * k);
  if (val1 * (k + 2) <= val2 * k) {
    cout << k << '\n';
  } else
    cout << k + 2 << '\n';
}
signed main() {
  ios::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  long long t;
  cin >> t;
  while (t--) solve();
}
