#include <bits/stdc++.h>
using namespace std;
const long double PI = 3.141592653589793238462643383279502884;
const long long PRIME1 = 1e9 + 7;
long long gcd(long long a, long long b) { return b ? gcd(b, a % b) : a; }
long long minll(long long a, long long b) { return a <= b ? a : b; }
long long maxll(long long a, long long b) { return a >= b ? a : b; }
int const MX = 200010;
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  int t;
  cin >> t;
  while (t--) {
    long long l, r, m;
    cin >> l >> r >> m;
    long long d = r - l;
    int f = 0;
    for (long long a = l; a <= r && !f; a++) {
      long long t1 = m % a;
      if (t1 <= d && t1 < m) {
        f = 1;
        cout << a << " " << l + t1 << " " << l << "\n";
        continue;
      }
      if (a - t1 <= d) {
        f = 1;
        cout << a << " " << l << " " << l + a - t1 << "\n";
        continue;
      }
    }
  }
  return 0;
}
