Im getting wrong output for Redundant parantheses can u tell me where am i going wrong?
Redundant Parantheses
Instead of making a bool variable, try to solve it using int variable. Hereβs my code for reference which will help you https://ide.codingblocks.com/s/353569
(a+(b)) for this input it shows Not redundant but it has duplicate
(a+(b)/c)β¦for this also Its duplicate but it shows not dupliate
Wait a minute @apoorv.chauhann, the question link you have provided is not opening, might be a glitch. Copy and paste that question here , as it might be something related to +,-,*,/.
@apoorv.chauhann try this one https://ide.codingblocks.com/s/337197 , due to some backend glitch I was unable to find that problem statement. This might help
Given a string of balanced expression, find if it contains a redundant parenthesis or not. A set of parenthesis are redundant if same sub-expression is surrounded by unnecessary or multiple brackets. Print βYesβ if redundant else βNoβ. Note: Expression may contain β+β, β*β, βββ and β/β operators. Given expression is valid and there are no white spaces present.
I request to modify the code that u sent me for refrence for the above problem statement
Itβs almost same @apoorv.chauhann , if you wonβt be able to understand anything in this code. You can ask me Iβll surely help you