Deviopath › Swift

Last Element

Easy · Collections

array.last is Int?. Return that value, or 0 if the array is empty.

Write last(_:).

Next: Guard the Score