I have a list of strings. Each string contains random text and a sequence of numbers and letters that may or may not match a regex.
Example string:
"Bla bla bla 123-abc-456 bla bla blaaha"
123-abc-456
will match a regex.
I wish to store all those matching sequences into a new list; sequence only that is, not the bla bla bla.
How could this be done? I need to break out the sequence only using the regex somehow.