Error_code List<List_entry>::remove(int position, List_entry &x)
{
if(count==0)
return underflow;
if(position<0||position>=count)
return range_error;
x=entry[position];
for(int i=position;i<=count-2;i++)
entry[i]=entry[i+1];
count--;
return success;
}
{
if(count==0)
return underflow;
if(position<0||position>=count)
return range_error;
x=entry[position];
for(int i=position;i<=count-2;i++)
entry[i]=entry[i+1];
count--;
return success;
}