Add check to validate paranthesis