}
void remove_number(int n) {
if( n >= total ) return;
- for(int i=n+1; i<total; ++i ) values[i-1]=values[i];
+ while( ++n<total ) values[n-1]=values[n];
remove();
}
void remove(TYPE value) {
}
void remove_object(TYPE value) { remove(value); del(value); }
void remove_object_number(int i) {
- if( i < total ) { del_value(i); remove_number(i); }
+ if( i < total ) { del_value(i); remove_number(i); }
else fprintf(stderr, "ArrayList<TYPE>::remove_object_number:"
" number %d out of range %d.\n", i, total);
}