how to solv mathematical equation

I want to make a php program which can solv this mathematical equation,
$question=“99/3*2+sqrt(2)-1”;

please help me.

Hi there,

Just remove the speech marks. If the answer is not what you want, you will need to manually add brackets to control the calculations’ order.

I read the title of the thread and thought “wow, can PHP solve EQUATIONS!!?!?”
and then I say an expression and laughed.

Hi,

$question=99/3*2+sqrt(2)-1;
echo $question;

This will give your equation’s answer.

Hope this will help you

Sponsor our Newsletter | Privacy Policy | Terms of Service