Regex solution
Need to understand whether there is a better solution out there.
Tags: discuss, regex, python