Bloomberg | Remove array elements in given index ranges
Anonymous User
8227
Oct 17, 2019
Oct 17, 2019

Remove ints from an array.

Example:

Input: array = [-8, 3, -5, 1, 51, 56, 0, -5, 29, 43, 78, 75, 32, 76, 73, 76], ranges = [[5, 8], [10, 13], [3, 6], [20, 25]]
Output: [-8, 3, -5, 29, 43, 76, 73, 76]

Is there a corresponding or relative leetcode question?

Comments (22)