Removes current element in array by swapping it with the end element and popping it from the end. This invalidates the current iterator value and it must be incremented. Note this modifies the order of the remaining elements in the array.