Trim a vector in place

resize!(v, length(v) - n)

More generally, to delete any sequence of indices, you could use deleteat!.

3 Likes