---
title: "remove(atOffsets:)"
framework: swift
role: symbol
role_heading: Instance Method
path: "swift/rangereplaceablecollection/remove(atoffsets:)"
---

# remove(atOffsets:)

Removes all the elements at the specified offsets from the collection.

## Declaration

```swift
mutating func remove(atOffsets offsets: IndexSet)
```

## Discussion

Discussion note: O(n) where n is the length of the collection.
