I have a expression containing extra brackets .Write an algo which can remove unwanted brackets like expression is (((a+d)*(a-2))) so we shuld be able to get (a+d)*(a-2)
One solution:
I have a expression containing extra brackets .Write an algo which can remove unwanted brackets like expression is (((a+d)*(a-2))) so we shuld be able to get (a+d)*(a-2)
One solution:
相关文章:
Think it will be good to start with converting this to Hungarian notation (using recursion)
And then convert back to normal view with brackets