#include<bits/stdc++.h>
using namespace std;
int main(){
int a[100][100],n,i,j;
cin>>n;
for(i=0;i<n;i++){
for(j=0;j<=i;j++){
if(j==0){
a[i][j]=1;
cout<<a[i][j]<<" ";
}else{
a[i][j]=a[i-1][j]+a[i-1][j-1];
cout<<a[i][j]<<" ";
}
}
cout<<endl;
}
}
/**************************************************************
Problem: 1275
User: wengsihan
Language: C++
Result: Accepted
Time:13 ms
Memory:2072 kb
****************************************************************/