---
title: "contains(_:)"
framework: swift
role: symbol
role_heading: Instance Method
path: "swift/collection/contains(_:)"
---

# contains(_:)

Returns a Boolean value indicating whether the collection contains the given sequence.

## Declaration

```swift
func contains<C>(_ other: C) -> Bool where C : Collection, Self.Element == C.Element
```

## Parameters

- `other`: A sequence to search for within this collection.

## Return Value

Return Value true if the collection contains the specified sequence, otherwise false.
