Reputation: 99
I have strings with pattern "ab234cafsd5464". I need to extract last part of the string which is a number. How do we do this in Lua?
Upvotes: 1
Views: 197
Reputation:
Perform an anchored match from the end of the string of one or more digits:
string.match("ab234cafsd5464", "%d+$")
Upvotes: 2