此函数的基本功能,并描述for语句执行的次数
1. 说明此函数的基本功能,并描述for语句执行的次数typedef struct
{int data[MAXSIZE];
int length;
}SeqList;
SeqList *L;
SeqList *AA(SeqList *L,int i,int x)
{
int j;
if (i<1 || i>L->length)
{ printf("the insert postion is errror!\n");
return(L);};
if (L->length==MAXSIZE)
{printf("the postion is overflow!\n");
return(L);};
for (j=L->length; j>=i; j--)
L->data[j+1]=L->data[j];
L->data[i]=x;
L->length++;
return(L);
}