Home HTML CSS JAVASCRIPT BOOTSTRAP Python Docker ML tutorial About us Privacy policy

Math Object



Math Object



In javaScript Math is a pree define class which contains pree define method and properties,so that we can use them in our programs.

Math.round()

Math.round() function is use to get round values of it's nearest integers.


Math.pow(x,y)

Math.pow(x,y) function is use to get power to the given number. Here x is a given number and y is power value.


Math.sqrt()

Math.sqrt() function is used to get root to the given number.


Math.abs()

Math.abs() function is use to get absloue values,which means always return's positive values.


Math.ceil()

Math.ceil() function is use to get rounded values up to nearest integer's.


Math.floor()

Math.floor() function is use to get downwords nearest integer's.

Math.random()

Math.random() function is used to get random values between 0 to 9.



Math.min()

Math.min() function is used to find lowest value in a list of arguments.

Math.max()

Math.max() function is used to find highest value in a list of arguments.


Math.PI property

Math.PI property is use to perform airthmatic operations.


Math.sin()

Math.sin() function is use to return sin values(values 1 and -1); we can convert a degree to radian. radian angle=Angle in degree*Math.PI/180;



Math.cos()

Math.cos() function is use to return cos values(values 1 and -1); we can convert a degree to radian. radian angle=Angle in degree*Math.PI/180;