1
2function deleteNodesBetween(nodeList, startValue, endValue) {
3 for (let actualValue = endValue - 1; actualValue >= startValue; actualValue -= 1) {
4 nodeList.item(actualValue).remove();
5 }
6}
7//deletes nodes from startValue to endValue
8//starts from the end value because starting from the
9//start value would cause some error with value position changing
10
11
12