I want to get the substring of all the characters after the last index of /
for example: "www.example.com/sfs3/dd/423"
desired output = 423
I've tried:
if let range = link.rangeOfString("/") { //does not give me the last index of / it gives me starting from the first / newlink = link.substringFromIndex(range.endIndex) }