<!--
{
  "availability" : [
    "iOS: 8.0.0 -",
    "iPadOS: 8.0.0 -",
    "macCatalyst: 13.0.0 -",
    "macOS: 10.10.0 -",
    "tvOS: 9.0.0 -",
    "visionOS: 1.0.0 -",
    "watchOS: 2.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Swift",
  "identifier" : "/documentation/Swift/JoinedSequence/init(base:separator:)",
  "metadataVersion" : "0.1.0",
  "role" : "Initializer",
  "symbol" : {
    "kind" : "Initializer",
    "modules" : [
      "Swift"
    ],
    "preciseIdentifier" : "s:s14JoinedSequenceV4base9separatorAByxGx_qd__tcSTRd__7Element_AFQZAFRtd__lufc"
  },
  "title" : "init(base:separator:)"
}
-->

# init(base:separator:)

Creates an iterator that presents the elements of the sequences
traversed by `base`, concatenated using `separator`.

```
init<Separator>(base: Base, separator: Separator) where Separator : Sequence, Separator.Element == Base.Element.Element
```

## Discussion> Complexity: O(`separator.count`).

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)