Category : algorithm

I am trying to split R15.49 to (R, 15.49) or ZAR15.49 to (ZAR, 15.49) I have tried one of the solutions here and implememted the function below: def splitCurrency(string): match ='([D]+)([d,]+)’, string) output = (,‘,’,”)) return output But I am getting (R, 15) or (ZAR, 15). and its ignoring the digits after the ..

Read more