Delete occurrences of an element if it occurs more than n times
Enough is enough!
Task
## NASM notes
Write the output numbers into the `out` parameter, and return its length.
The input array will contain only integers between 1 and 50 inclusive. Use it to your advantage.For C:
* Assign the return array length to the pointer parameter `*szout`.
* Do not mutate the input array.Example
delete_nth ([1,1,1,1],2) # return [1,1]
delete_nth ([20,37,20,21],1) # return [20,37,21]Solutions
π§ C++
Last updated