Sathish David Kumar N
asked on
How to Split nested () praceket
Hi,
I want to Split String
add(add(15,add(4,5)),5)
my result should be
add(4,5)
add(15,add(4,5))
add(add(15,add(4,5)),5)
how to do this ..? can any one give me some idea ?
I want to Split String
add(add(15,add(4,5)),5)
my result should be
add(4,5)
add(15,add(4,5))
add(add(15,add(4,5)),5)
how to do this ..? can any one give me some idea ?
This is a duplicate of the following, essentially
https://www.experts-exchange.com/questions/28482815/how-to-split-the-string.html
https://www.experts-exchange.com/questions/28482815/how-to-split-the-string.html
ASKER
ya . correct. here i mention my question clearly. thats why i created new one.
i created this pattern
(\\(([^()]*|\\([^()]*\\))* \\)) its show the brackets but not nested . can you help me on this cehj???????
i created this pattern
(\\(([^()]*|\\([^()]*\\))*
I already have - the answer is the same as before
ASKER
not only add will string it may verie length() . so depend upon on the add or length function only we decide its no or size
eg:
add(15,length(4,5)) output should be no(15)+size(4,5)
before split i need to find wich function it is? thats the pblm i am facing
eg:
add(15,length(4,5)) output should be no(15)+size(4,5)
before split i need to find wich function it is? thats the pblm i am facing
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Meanwhile I developed a recursive version of it, simpler and more effective, do you need it?
ASKER
eg:
add(add(15,add(4,add(5,4))
or
add(add(15,5),5) how to do that??please help me give some tips !!