#include <bits/stdc++.h>
using namespace std;
bool fi = true;
const unsigned long long MOD = 1e9 + 7;
int main() {
  ios::sync_with_stdio(false);
  cin.tie(0), cout.tie(0);
  int t;
  cin >> t;
  int a[1005];
  while (t--) {
    int n;
    cin >> n;
    for (long long i = 0; i < n; ++i) {
      cout << 1 << (i == n - 1 ? '\n' : ' ');
    }
  }
}
