一:
#include<stdio.h>
void main()
{
long a[]={5,10,10,10,11,12,13,5,5,5,10,20,20,10,10,10,10,10,10,10,20,20,20,60,50,20,20,40,40,40,30,30,20,20,20,20,20,40,40,40,20,20,40,20,20,20,20,40,40,40,20,20,20,20,20,20,20,40,40,40,10,20,50,20,20,20,60,67,40,40,20,10,50,20,20,107,60,20,20,10,10,127,40,40,40,20,10,10,10,10,40,40,40,20,20,20,20,20,20,100};
int i=0,j,k=1,m;
long z[100];
for(i=0;i<100;i++)
{
printf("%6d",a[i]);
if((i+1)%10==0)
printf("\n");
}
printf("\n\n\n\n\n");
for(m=0;m<100;m++)
{
if(m==0)
z[m] = a[m];
else
z[m] = a[m] - a[m-1];
printf("%6d",z[m]);
if((m+1)%10==0)
printf("\n");
}
printf("\n\n\n\n\n");
for(i=0;i<100;i++)
{
if((i+1)%10==0)
k++;
if(i<10)
j = i+1;
else
if(i%10==9)
j = i+1-(k-2)*10;
else
j = i+1-(k-1)*10;
if(z[i+1] != z[i])
{
printf("(%d,%d)",z[i],j);
printf(" ");
if(j==10)
printf("\n");
}
}
}
#include<stdio.h>
void main()
{
long a[][2]={{5,2},{0,4},{1,7},{-8,8},{0,10},{10,2},{0,3},{-10,4},{0,10},{20,1},{0,3},{40,4},{-10,5},{-30,6},{0,7},{20,8},{0,10},{30,1},{0,2},{-10,3},{0,7},{20,8},{0,10},{20,1},{0,2},{20,3},{-20,4},{0,7},{20,8},{0,10},{20,1},{0,7},{20,8},{0,10},{10,2},{30,3},{-30,4},{0,6},{40,7},{7,8},{-27,9},{0,10},{20,1},{-10,2},{40,3},{-30,4},{0,5},{87,6},{-47,7},{-40,8},{0,9},{-10,10},{10,1},{117,2},{-87,3},{0,5},{-20,6},{-10,7},{0,10},{40,1},{0,4},{-20,5},{0,9},{80,10}};
int i,j,k=0,s,t=0,r,m,n=0;
long z[100],d[100];
printf("(");
for(i=0;i<64;i++)
for(j=0;j<2;j++)
{
printf("%d",a[i][j]);
k++;
if(k%2==1)
printf(",");
if(k%2==0)
printf(") (");
}
printf("\n\n\n");
for(i=0;i<64;i++)
{
if(a[i-1][1] != 10)
r=(a[i][1]-a[i-1][1]);
else
r=a[i][1];
for(s=1;s<=r;s++)
{
printf("%5d",a[i][0]);
t++;
m =t-1;
d[m] = a[i][0];
if(t%10==0)
printf("\n");
}
}
printf("\n\n\n\n");
for(m=0;m<100;m++)
{
if(m==0||m==10*n)
z[m] = d[m];
else
z[m] = z[m-1] + d[m];
printf("%5d",z[m]);
if((m+1)%10==0)
{
n++;
printf("\n");
}
}
}