init(scalars:shape:)
Creates a shaped array type from an array of values.
Declaration
init<S>(scalars: S, shape: [Int]) where S : Sequence, Self.Scalar == S.ElementParameters
- scalars:
A sequence of values.
- shape:
An integer array. Each element represents the size of the shaped array’s corresponding dimension.