#include <bits/stdc++.h>
using namespace std;
int mod = 1e9 + 7;
void solve() {
  int l, r;
  long long m;
  cin >> l >> r >> m;
  if (m < l) {
    cout << l << " " << l << " " << 2 * l - m << "\n";
    return;
  }
  int modulo = l, minimum = min(m % l, l - m % l);
  for (int i = l + 1; i < 2 * l && i <= r; ++i) {
    if (minimum > m % i || minimum > i - m % i) {
      minimum = min(m % i, i - m % i);
      modulo = i;
    }
  }
  cout << modulo << " ";
  if (minimum == modulo - m % modulo)
    cout << l << " " << l + minimum;
  else
    cout << l + minimum << " " << l;
  cout << "\n";
}
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  int t;
  cin >> t;
  cout << fixed << setprecision(15);
  while (t--) solve();
  return 0;
}
