Test case is wrong

Test case for this questions is wrong both are duplicates

Testcases are right. In first testcase if we remove the first and last bracket of string then also the resultant string is balanced. In second testcase we do not have such pair of chars to remove.

What about parenthesis around b

According to the question duplicate paranthesis means an expression contains multiple paranthesis. Since expression b in second case has only one pair of balanced paranthesis i.e. (b) so, it is not duplicate.