Math.exp()
함수는 x
를 인수로 하는 ex
값을 반환합니다. 그리고 e
는 오일러 상수(또는 네이피어 상수)는 자연 로그의 밑입니다.
The source for this interactive example is stored in a GitHub repository. If you'd like to contribute to the interactive examples project, please clone https://github.com/mdn/interactive-examples and send us a pull request.
구문
Math.exp(x)
매개변수
x
- 숫자
반환 값
e
는 오일러 상수이고 x
는 인수인 ex
값
Description
exp()
는 Math
의 정적 메소드이기 때문에 새로 작성한 Math
오브젝트 대신에 항상 Math.exp()
의 형태로 써야 합니다. (Math
는 생성자가 아닙니다.)
예시
Math.exp() 사용 예
Math.exp(-1); // 0.36787944117144233
Math.exp(0); // 1
Math.exp(1); // 2.718281828459045
설명
설명 | 상태 | 비고 |
---|---|---|
ECMAScript 1st Edition (ECMA-262) | Standard | 최초의 정의. JavaScript 1.0.에서 첫 시행. |
ECMAScript 5.1 (ECMA-262) The definition of 'Math.exp' in that specification. |
Standard | |
ECMAScript 2015 (6th Edition, ECMA-262) The definition of 'Math.exp' in that specification. |
Standard | |
ECMAScript (ECMA-262) The definition of 'Math.exp' in that specification. |
Living Standard |
브라우저 호환성
BCD tables only load in the browser
The compatibility table in this page is generated from structured data. If you'd like to contribute to the data, please check out https://github.com/mdn/browser-compat-data and send us a pull request.