#include <bits/stdc++.h>
using namespace std;
long long gcdfun(long long x, long long y) {
  if (y == 0)
    return x;
  else
    return gcdfun(y, x % y);
}
void swap(long long* x, long long* y) {
  long long temp;
  temp = *x;
  *x = *y;
  *y = temp;
}
long long minfun(long long a, long long b) {
  if (a < b)
    return a;
  else
    return b;
}
long long power(long long a, long long n) {
  if (n == 0) return 1;
  long long p = power(a, n / 2);
  p *= p;
  p = p % 998244353;
  if (n & 1) p *= a;
  return p % 998244353;
}
long long mul(long long a, long long b) { return (a * b) % 998244353; }
void solve() {
  int n;
  cin >> n;
  for (int i = 0; i < n; i += 1) cout << 1 << " ";
}
int main() {
  int t = 1;
  cin >> t;
  while (t--) {
    solve();
    cout << '\n';
  }
}
