| [ Web Proxy ] |
| Viewing: https://developer.mozilla.org/ja/docs/Web/JavaScript/Reference/Global_Objects/Math/min | [Back] [Original] |
Get to know MDN better
console.log(Math.min(2, 3, 1));
// : 1
console.log(Math.min(-2, -3, -1));
// : -3
const array = [2, 3, 1];
console.log(Math.min(...array));
// : 1
Math.min()
Math.min(value1)
Math.min(value1, value2)
Math.min(value1, value2, /* , */ valueN)
min() Math Math.min() Math (Math )
Math.min.length 2 2
x y z
const x = 10;
const y = -20;
const z = Math.min(x, y); // -20
Math.min()
let x = f(foo);
if (x > boundary) {
x = boundary;
}
const x = Math.min(f(foo), boundary);
| ECMAScript 2027 LanguageSpecification # sec-math.min |
| Web Proxy Viewer | New URL | Original Page |