How can i make the php cos function return the correct value?

后端 未结 3 941
情深已故
情深已故 2021-01-19 01:50

I\'ve tried

$x = cos(deg2rad($angle));

but it returns 6.12323399574E-17 when the angle is 90 degrees instead of 0. I read that this is a fl

3条回答
提交回复
热议问题