Math 객체의 cos() 함수는 각도(라디안)를 받아들이고 코사인 값을 반환합니다.
구문
구문은 다음과 같습니다.
Math.cos(90)
예시
<html>
<head>
<title>JavaScript Example</title>
</head>
<body>
<script type="text/javascript">
var result = Math.cos(90);
document.write("cosine value of the given angle: "+result);
</script>
</body>
</html> 출력
cosine value of the given angle: -0.4480736161291702