#include <bits/stdc++.h>
using namespace std;
long long int binary_expo(long long int base, long long int pw) {
  long long int res = 1;
  while (pw) {
    if (pw % 2) {
      res *= base;
      res %= 1000000007;
      pw -= 1;
    } else {
      base *= base;
      base %= 1000000007;
      pw /= 2;
    }
  }
  return res;
}
long long int mod_inv(long long int k) {
  return binary_expo(k, 1000000007 - 2);
}
int t;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0), cout.tie(0);
  cin >> t;
  while (t--) {
    int n;
    cin >> n;
    for (int i = 0; i < n; i++) cout << 1 << " ";
    cout << endl;
  }
  return 0;
}
