in reply to extract only uppercases from string

Use character classes, grouping and global matching (m//g).
Also, have a look at split and there is no ACTG in your string.
Edit: fixed link
Sorry if my advice was wrong.
  • Comment on Re: extract only uppercases from string