Using regex, you can use a pattern that takes three comma-separated elements and then extracts the third element from inside the brackets.