#include <bits/stdc++.h>
#pragma Optimize("O3")
using namespace std;
long long n, x, a, b, c, y, m, ans;
vector<int> v;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  long long t, l, r;
  cin >> t;
  while (t--) {
    cin >> l >> r >> m;
    for (int a = l; a <= r; a++) {
      n = ceil(1.0 * m / a);
      long long dif = n * a - m;
      b = l;
      c = l + dif;
      bool ok = true;
      if (dif > r - l) {
        n--;
        dif = m - n * a;
        if (dif > r - l) ok = false;
        b = r;
        c = r - dif;
      }
      if (ok) {
        cout << a << ' ' << b << ' ' << c << '\n';
        break;
      }
    }
  }
  return 0;
}
