---
title: "init(_:)"
framework: swift
role: symbol
role_heading: Initializer
path: "swift/simd8/init(_:)-3ewxg"
---

# init(_:)

Creates a vector from the given sequence.

## Declaration

```swift
init<S>(_ scalars: S) where S : Sequence, Self.Scalar == S.Element
```

## Parameters

- `scalars`: The elements to use in the vector.

## Discussion

Discussion note: scalars must have the same number of elements as the vector type.
