$string = 'The (use {of}) parentheses (indicates that the (writer [considered] the {information}) less an afterthought).'; Output: pattern:'(use {of})' rightside of pattern:' parentheses (indicates that the (writer [considered] the {information}) less an afterthought).' leftside of pattern:'The'