{
int [][]a= new int[7][] ;
a[0] = new int[1]; //a[0][0]=1;
a[1] = new int[2] ;
for (int i = 0; i < 7; i++)
{
a[i] = new int[i+1] ;
a[i][0] =1;
a[i][i]=1;
if(i>1)//求出中间的数据
{
for(int j=1;j<i; j++)
{
a[i][j]= a[i-1][j-1]+a[i-1][j];
}
}
}
for (int i=0; i<a.Length; i++)
{
for (int k = 0; k < a.Length-1-i; k++)
{
Console.Write(" ");
}
for(int j=0;j<a[i].Length; j++ )
{
Console.Write(a[i][j] + " ");
}
Console.WriteLine();
}
}
}