---
title: "minus(_:)"
framework: foundation
role: symbol
role_heading: Instance Method
path: "foundation/nsmutableset/minus(_:)"
---

# minus(_:)

Removes each object in another given set from the receiving set, if present.

## Declaration

```swift
func minus(_ otherSet: Set<AnyHashable>)
```

## Parameters

- `otherSet`: The set of objects to remove from the receiving set.

## See Also

### Related Documentation

- [remove(_:)](foundation/nsmutableset/remove(_:).md)
- [removeAllObjects()](foundation/nsmutableset/removeallobjects().md)

### Combining and recombining sets

- [union(_:)](foundation/nsmutableset/union(_:).md)
- [intersect(_:)](foundation/nsmutableset/intersect(_:).md)
- [setSet(_:)](foundation/nsmutableset/setset(_:).md)
