I have a list of names in an array in Ruby:
names = ["John Smith","Bob Miller"]
So I want to do a regex and get this array:
namesRegex = ["JS","BM"]
This is, I extract the uppercase characters from the string, merge them and put them in a new array.
Any help is appreciated.