Please turn on JavaScript in your browser and refresh the page to view its content.
Availability 有効性
Technology
On This Page この項には
var last: (T.Value?, U.Value?, V.Value?, Range<AttributedString.Index>)? { get }
Value
Range
AttributedString
Index
If the collection is empty, the value of this property is nil. コレクションが空であるならば、このプロパティはnilです。
nil
let numbers = [10, 20, 30, 40, 50] if let lastNumber = numbers.last { print(lastNumber) } // Prints "50"
Complexity: O(1) 計算量:O(1)