#include <bits/stdc++.h>
using namespace std;
const int N = 1e2 + 5;
int n, m, row[N], clm[N];
bool sq(long long x) {
  long long st = 0, en = 1e9;
  while (st < en) {
    long long mid = (st + en + 1) / 2;
    if (mid * mid <= x)
      st = mid;
    else
      en = mid - 1;
  }
  return st * st == x;
}
bool init(int sz, int a[], int i, long long sum) {
  if (i == sz) return sq(sum);
  for (int j = 1; j < 10; ++j) {
    a[i] = j;
    if (init(sz, a, i + 1, sum + 1ll * j * j)) return 1;
  }
  return 0;
}
int main() {
  cin >> n >> m;
  init(n, row, 0, 0);
  init(m, clm, 0, 0);
  for (int i = 0; i < n; ++i) {
    for (int j = 0; j < m; ++j) printf("%lld ", 1ll * row[i] * clm[j]);
    puts("");
  }
  return 0;
}
