Instance Method インスタンスメソッド

index(of:)

Returns the first index where the specified value appears in the collection. 指定された値がコレクションにおいて現れるところの最初のインデックスを返します。

Declaration 宣言

func index(of element: Self.Element) -> Self.Index?
Available when Element conforms to Equatable. ElementEquatableに準拠する時に利用可能です。