I have a problem with my code. I use "eval()" and the problem is that I have a lot of resultat like it :
7*1*6*10-9+3 => 414
7*1*6*10-9-3 => 408
7*1*6*10-9*3 => 393
7*1*6*10-9/3 => 417.0
7*1*6*10/9*3 => 140.0
7*1*6/10*9*3 => 113.4
7*1/6+10*9*3 => 271.1666666666667
7*1/6*10*9+3 => 108.00000000000001
7*1/6*10*9-3 => 102.00000000000001
7*1/6*10*9*3 => 315.00000000000006
7/1+6+10*9+3 => 106.0
7/1+6+10*9*3 => 283.0
7/1+6*10*9+3 => 550.0
7/1+6*10*9-3 => 544.0
My code to get the result is
eval(operation), like eval('7*1*6*10-9+3') etc
I would like not display the decimal number like 33,33 or 102,000001. But I would like display 106.0 without the ",0" just like it : "106"
Thanks for reading me !!