Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

how to get last element of an array in swifg

let myArray = ["Hello!", "World!"]
let capacity = myArray.count
let lastElement = myArray[capacity-1]
print(lastElement)
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #element #array #swifg
ADD COMMENT
Topic
Name
9+9 =