p5.js | radians() Function
The radians() function in p5.js is used to convert a given degree measurement value to its corresponding value in radians.
radians( degrees )
Parameters: This function accepts single parameter degrees which is to be converted into radians.
Return Value: It returns the converted radians value of angle.
Below programs illustrate the radians() function in p5.js:
Example 1: This example uses radians() function to convert a given degree to its corresponding radians.
Example 2: This example uses radians() function to convert a given degree to its corresponding radians.