Hi
I am trying to write a regular expression to match any string that satisfies the following criteria.
The string begins and ends with a matching pair of parentheses '(' ')'
There may be any number of parentheses within it.
For example my regex shud match :
( ( p(x)+q(x) ) . (p(x) * q(x) ) )
but not match
( p(x)+q(x) ) . ( p(x) * q(x) )
How do i write such a regex