#include <bits/stdc++.h>
using namespace std;
const int N = 2e5 + 10, mod = 1e9 + 7;
int h, c, t;
long double get(int x) {
  long double cur = ((x / 2) + (x % 2)) * 1ll * h + (x / 2) * 1ll * c;
  cur /= x;
  return cur;
}
int main() {
  int tc = 1;
  scanf("%d", &tc);
  for (int cn = 1; cn <= tc; cn++) {
    scanf("%d%d%d", &h, &c, &t);
    long double best = (h + c) / (double)2;
    int l = 0, r = 1e8, res = 1;
    while (l <= r) {
      int mid = l + (r - l) / 2;
      int odd = 1 + 2ll * mid;
      if (get(odd) < t)
        r = mid - 1;
      else {
        res = odd;
        l = mid + 1;
      }
    }
    int ans = 2;
    if (abs(t - get(res)) < abs(t - best)) {
      ans = res;
      best = get(res);
    }
    if (abs(t - get(res + 2)) < abs(t - best)) ans = res + 2;
    printf("%d\n", ans);
  }
  return 0;
}
