Returns the last element after splitting the string using the specified pattern. If the string cannot be split, it returns the original string.
pattern
string lastSplit(Pattern pattern) => split(pattern).last;