This commit is contained in:
Варвара Карасева 2024-11-06 09:18:49 +04:00
parent 5b988e7ee8
commit 7b86e132f6

View File

@ -285,18 +285,5 @@ void Menshe4() {
} }
} }
void deleteElement(int delIndex) {
for (int i = delIndex; i < n - 1; i++) {
arr[i] = arr[i + 1];
}
n--;
}
void insertElement(int insIndex, int value) {
for (int i = n; i > insIndex; i--) {
arr[i] = arr[i - 1];
}
n++;
arr[insIndex] = value;
}