What's wrong in this code? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 1

What's wrong in this code?

When we pass the value in sin function, what does it actually consider? Degree or radian https://code.sololearn.com/cosZK6Y79w4F/?ref=app

27th Oct 2019, 7:43 AM
Rushi
1 Answer
+ 6
math.sin(x) Return the sine of x radians. https://docs.python.org/3/library/math.html#math.sin Use math.sin(math.degrees(x)) instead.
27th Oct 2019, 8:42 AM
Diego
Diego - avatar