#include<cstdio>
#include<cstdlib>
#include<cstring>
#include<cmath>
#include<algorithm>
#include<functional>
#include<vector>
#include<queue>
#include<stack>
#include<set>
#include<map>
using namespace std;
#define MOD 1000000007
#define f(i,n) for(long long i=0;i<(long long)(n);i++)
#define N 200010






int main() {
	int k, x;
	int n;
	scanf("%d", &n);
	f(i, n-1) {
		f(j, n - i - 1) {
			k = 1;
			x = j + 1;
			while (x % 2 == 0) {
				x = x / 2;
				k++;
			}
			printf("%d", k);
			if(j<(n-i-2))printf(" ");
		}
		printf("\n");
	}
	return 0;
}