3.10
8从有序链表L中删除链表L本身所给位置上的节点。例如,如果L=(1 3 5 7 8),那么删除之后,L=(3 7)。
void delete_itself(List la) {
cout << "Please input the number of place: " << endl;
int n;
cin >> n;
int *a = new int[n];
cout << "Please input the value of place: " << endl;
for (int i = 0; i < n; i++)
{
cin >> a[i];
}
List pa;
int temp, j=0;
pa = la;
while (j!=n)
{
temp = a[j];
Spec_Delete(pa, temp);
j++;
}
find_List(pa);
//outputlist(pa);
}