add another impl for generating parantheses