| [ Web Proxy ] |
| Viewing: https://developer.mozilla.org/ja/docs/Web/JavaScript/Reference/Global_Objects/Math/E | [Back] [Original] |
Get to know MDN better
function compoundOneYear(interestRate, currentVal) {
return currentVal * Math.E ** interestRate;
}
console.log(Math.E);
// : 2.718281828459045
console.log((1 + 1 / 1000000) ** 1000000);
// : 2.718280469 (approximately)
console.log(compoundOneYear(0.05, 100));
// : 105.12710963760242
Math.E | |
|---|---|
E Math Math Math.E Math
e
function getNapier() {
return Math.E;
}
getNapier(); // 2.718281828459045
| ECMAScript 2027 LanguageSpecification # sec-math.e |
| Web Proxy Viewer | New URL | Original Page |