remove last element in array swift code example
Example: pop last element array swift
// Initialize the Array
var a = [1,2,3]
// Remove last item
let lastItem = a.removeLast()
print(lastItem)
print(a)
// Initialize the Array
var a = [1,2,3]
// Remove last item
let lastItem = a.removeLast()
print(lastItem)
print(a)