Шпаргалка: Реализация списка
{Tree *PL=L;
if (PL->LP!=NULL)
{PL=PL->LP;
Erase(PL);}
if (PL->RP!=NULL)
{PL=PL->RP;
Erase(PL);}
PL->LP=NULL;
PL->RP=NULL;
}
void TreeWork::EraseList()
{if (BegP!=NULL)
{do
{List *PList1=BegP->LNext;
PList=PList1->LNext;
BegP->LNext=PList;
PList->LPrev=BegP;
Erase(PList1->Root);
delete [] PList1;
}
while (PList!=BegP);
BegP=NULL; PList=NULL;
}
}
int TreeWork::DeleteElement()
{cout<<endl<<"Input number of element: ";
int Number=0;
cin>>Number;
if (Number>ElementQuantity || Number<0)