I am using a var for IPAddress, for which i wanted to remove trailing slash (/). Now i see a warning that 'var' is deprecated. In such case how can i use removeAtIndex method in new style?
if ipAddress.characters.last == "/" {
ipAddress.removeAtIndex(ipAddress.endIndex.predecessor())
}