Driver code
int main ( ) { string exp1 = " ( ( ( ) ) ) ( ) ( ) " ; if ( isBalanced ( exp1 ) ) cout << " Balanced ▁ STRNEWLINE " ; else cout << " Not ▁ Balanced ▁ STRNEWLINE " ; string exp2 = " ( ) ) ( ( ( ) ) " ; if ( isBalanced ( exp2 ) ) cout << " Balanced ▁ STRNEWLINE " ; else cout << " Not ▁ Balanced ▁ STRNEWLINE " ; return 0 ; }