I'm trying to split the mathematical strings on maths operators. for example
expression = "7*6+3/2-5*6+(7-2)*5"
I need to tokenize it to produce:
expressionArray = ["7","*","6","+","3","/","2","-","5","*","6"]
I tried finding the solution here and this is what i get
expressoinArray=expression.split("(?<=[-+*/])|(?=[-+*/]")
but looks like this is not fetching the desired result for expression
.