Hello,
How in PHP lang i can write and have same result
300cos12+400sin12×400cos12+300sin12≈376.6×453.6
Hello,
How in PHP lang i can write and have same result
300cos12+400sin12×400cos12+300sin12≈376.6×453.6
[php]$num = 12;
echo 376.6 * 453.6;
echo ‘
’;
$c = deg2rad($num);
echo $answer = (300 * cos($c) + 400 * sin($c)) * ( 400 * cos($c) + 300 * sin($c));[/php]
I think php approximation could be a little bit better, but it works.
You can make the formula even more versatile by replacing the other numbers with variable names.