public class YangHui{
public static void main(String[] args) {
int a[][]=new int[11][11];
int i,j;
for(i=0;i<11;i++){
for(j=0;j<=i;j++){
a[i][0]=1;
if(i==j)
a[i][j]=1;
}
}
for(i=0;i<11;i++)
for(j=1;j<=i;j++)
a[i][j]=a[i-1][j-1]+a[i-1][j];
for(i=0;i<11;i++){
for(j=0;j<=i;j++)
System.out.println(" "+a[i][j]);
System.out.println();
}
}
}