index(before:)
Returns the position immediately before the given index.
Declaration
func index(before i: Int) -> IntParameters
- i:
A valid index of the collection.
imust be greater thanstartIndex.
Return Value
The index immediately before i.
Returns the position immediately before the given index.
func index(before i: Int) -> IntA valid index of the collection. i must be greater than startIndex.
The index immediately before i.