#include <bits/stdc++.h>
using namespace std;
int main() {
  int t;
  cin >> t;
  while (t--) {
    int n;
    cin >> n;
    if (n == 1) {
      cout << 4 << endl;
      continue;
    } else {
      for (int i = 1; i < n; i++) cout << 4 << ' ';
    }
    cout << 4 << endl;
  }
}
