I just want to be able to split both a +
and -
into a single array.
array = []
function = x+y-z
array = function.split("+")
array = function.split("-")
Expected output:
[x, y, z]
Obviously this isn't correct but can someone provide a real example?