You can crack it with a regex:
'Marry Jo Poppins'.replace(/^.*\s+(\w)\w+$/, "$1"); // P 'Anamaria Forrest Gump'.replace(/^.*\s+(\w)\w+$/, "$1"); // G
Otherwise, Mark B's answer is fine too :)
Edit
Alsciende regex + javascript combo myString.match(/(\w)\w*$/)[1] is probably a bit more versatile than mine.
regular expression explanation
/^.*\s+(\w)\w+$/ ^ beginning of input string .* followed by any character (.) 0 or more times (*) \s+ followed by any whitespace (\s) 1 or more times (+) ( group and capture to $1 \w followed by any word character (\w) ) end capture \w+ followed by any word character (\w) 1 or more times (+) $ end of string (before newline (\n))
Re-expression of Alsciende
/(\w)\w*$/ ( group and capture to $1 \w any word character ) end capture \w* any word character (\w) 0 or more times (*)
Summary
Regular expressions are extremely effective, or, as you might say, "God!" Regular-Expressions.info is a great starting point if you want to know more.
Hope this helps :)
maček source share