#include <bits/stdc++.h>
using namespace std;
int main() {
  int Test;
  scanf("%d", &Test);
  while (Test--) {
    int n;
    scanf("%d", &n);
    for (int i = 1; i < n; ++i) printf("1 ");
    printf("1\n");
  }
  return 0;
}
