#include <bits/stdc++.h>
using namespace std;
void err(istream_iterator<string> it) {}
template <typename T, typename... Args>
void err(istream_iterator<string> it, T a, Args... args) {
  cerr << *it << " = " << a << "\n";
  err(++it, args...);
}
mt19937 rng(chrono::steady_clock::now().time_since_epoch().count());
const long long int INF = (long long int)(1e18) + 7;
signed main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  long long int n, m, t, i, j, k, ans = 0;
  cin >> t;
  while (t--) {
    cin >> n;
    while (n--) cout << 1 << " ";
    cout << "\n";
  }
  return 0;
}
