Because I’m working with a stupid schema, I need to pull the last name from a full name in a dataset, e.g.:
John Francis --> Francis
I’m using this.match(/\s+(\w+.*$)/)
which almost does what I want BUT returns the last name like " Francis". I’ve tried chaining the .strip method, but that barfs. I figure that the parens should return only the last name w/o the space, but it does not. I can’t see any other Ruby string functions that would help. Any ideas?