Posts by Felipe Saraiva • 33 points
1 post
-
2
votes2
answers1848
viewsQ: Treat division by zero
I have the following function in PHP: public function teste() { $conta = "0/(0+0+0)"; eval('$result = (' . $conta . ');'); echo $result; } In this case, the formula (in example 0/(0+0+0) obviously…