The following is from Introduction to Metamathematics by Steven Kleene. In Lemma 2 of section 7 of chapter 2, it seems ambiguous what constitutes a “set of parentheses.” Here are some relevant passages:
Proper pairing: a one-to-one pairing between n left parentheses "(" and n right parentheses ")" such that for each pair left parenthesis is on the left from the right parenthesis and if no two pairs separate each other.
Pairs of parentheses that separate each other - two pairs separate each other if they occur in the order (()).
Lemma 2 is as follows, in which I am uncertain as to the interpretation of “set of 2n parentheses…”
Lemma 2: A set of 2 parentheses admits at most one proper pairing.
What constitutes a pair of parentheses in a formula, and how are two distinct sets of parentheses distinguished? For instance, given the string “abc” are (a)bc and (abc) both a set of 2n parentheses (for n=1)? Otherwise, another scenario I can imagine is a pair of parenthesis being fixed in place in a formula, and the possibility of swapping the left and right mates is the only ‘degree of freedom’ in maintaining the “same set” criterion, but allowing for different strings of symbols.
Would anyone please illuminate this as it is meant to be intended?