Math
Об'єкт – простір імен Math
містить статичні властивості та методи математичних сталих та функцій.
Math
працює з числами типу Number
. Він не підходить для роботи з BigInt
.
Опис
На відміну від більшості глобальних об'єктів, Math
не є конструктором. Його не можна використовувати з оператором new
або викликати об'єкт Math
як функцію. Всі властивості та методи Math
є статичними.
Примітка: Чимало функцій
Math
мають точність обчислень, залежну від конкретної реалізації.Це означає, що різні браузери можуть давати різні результати. Навіть один і той самий JavaScript-рушій на різних ОС чи архітектурах процесора може видавати різні результати!
Статичні властивості
Math.E
Число Ейлера, основа натуральних логарифмів. Приблизно дорівнює
2.718
.Math.LN10
Натуральний логарифм числа
10
. Приблизно дорівнює2.303
.Math.LN2
Натуральний логарифм числа
2
. Приблизно дорівнює0.693
.Math.LOG10E
Логарифм числа
e
за основою10
. Приблизно дорівнює0.434
.Math.LOG2E
Логарифм числа
e
за основою2
. Приблизно дорівнює1.443
.Math.PI
Значення відношення довжини кола до його діаметра, наближено дорівнює
3.14159
.Math.SQRT1_2
Квадратний корінь з ½. Наближено дорівнює
0.707
.Math.SQRT2
Квадратний корінь з
2
. Наближено дорівнює1.414
.Math[Symbol.toStringTag]
Початкове значення властивості
Symbol.toStringTag
– рядок"Math"
. Ця властивість використовується вObject.prototype.toString()
.
Статичні методи
Math.abs()
Повертає модуль вихідного числа.
Math.acos()
Повертає арккосинус вихідного числа.
Math.acosh()
Повертає гіперболічний арккосинус вихідного числа.
Math.asin()
Повертає арксинус вихідного числа.
Math.asinh()
Повертає гіперболічний арксинус числа.
Math.atan()
Повертає арктангенс вихідного числа.
Math.atan2()
Повертає арктангенс частки переданих аргументів.
Math.atanh()
Повертає гіперболічний арктангенс вихідного числа.
Math.cbrt()
Повертає кубічний корінь вихідного числа.
Math.ceil()
Повертає найменше ціле число, яке дорівнює, або більше за
x
.Math.clz32()
Повертає кількість старших нульових бітів 32-бітового цілого вихідного числа.
Math.cos()
Повертає косинус вихідного числа.
Math.cosh()
Повертає гіперболічний косинус вихідного числа.
Math.exp()
Повертає результат обчислення виразу ex, де x — це аргумент, а e — число Ейлера (
2.718
…, основа натурального логарифма).Math.expm1()
Повертає результат віднімання
1
від значенняexp(x)
.Math.floor()
Повертає найбільше ціле число, яке дорівнює, або менше за
x
.Math.f16round()
Повертає найближче дробове представлення вихідного числа з половинною точністю.
Math.fround()
Повертає найближчий відповідник
x
у форматі числа з рухомою комою одинарної точності.Math.hypot()
Повертає квадратний корінь з суми квадратів переданих аргументів.
Math.imul()
Повертає результат 32-бітового цілочисельного множення вихідних чисел.
Math.log()
Повертає натуральний логарифм (㏒e, або ln) вихідного числа.
Math.log10()
Повертає логарифм аргументу
x
за основою10
.Math.log1p()
Повертає натуральний логарифм (㏒e, або ln) значення виразу
1 + x
, обчисленого для аргументуx
.Math.log2()
Повертає логарифм вихідного числа за основою
2
.Math.max()
Повертає найбільше значення з-поміж нуля чи більше аргументів.
Math.min()
Повертає найменше значення з-поміж нуля чи більше аргументів.
Math.pow()
Повертає результат піднесення
x
до степеняy
(тобтоx
y
).Math.random()
Повертає псевдовипадкове число від
0
до1
.Math.round()
Повертає значення вихідного числа, округлене до найближчого цілого.
Math.sign()
Повертає знак переданого вихідного числа. Вказує на те, чи є воно додатним, від'ємним, або нулем.
Math.sin()
Повертає синус вихідного числа.
Math.sinh()
Повертає гіперболічний синус вихідного числа.
Math.sqrt()
Повертає додатний квадратний корінь з вихідного числа.
Math.tan()
Повертає тангенс вихідного числа.
Math.tanh()
Повертає гіперболічний тангенс вихідного числа.
Math.trunc()
Повертає цілу частину вихідного числа, відкидаючи всі цифри після коми.
Приклади
Перетворення між градусами та радіанами
Тригонометричні функції: sin()
, cos()
, tan()
, asin()
, acos()
, atan()
, та atan2()
— приймають (і повертають) кути в радіанах.
Оскільки люди мають схильність оперувати кутами в градусах, та й деякі функції (наприклад, CSS-трансформації) можуть приймати градуси, корисно мати напохваті функції для переведення значень з градусів у радіани, і навпаки:
function degToRad(degrees) {
return degrees * (Math.PI / 180);
}
function radToDeg(rad) {
return rad / (Math.PI / 180);
}
Обчислення висоти рівностороннього трикутника
Якщо потрібно обчислити висоту рівностороннього трикутника, і відомо, що довжина його сторони — 100, — можна застосувати формулу довжина прилеглого катета, помножена на тангенс кута, дорівнює довжині протилежного катета.
В JavaScript можна виконати це обчислення наступним чином:
50 * Math.tan(degToRad(60));
Тут використана функція degToRad()
для переведення 60 градусів у радіани, оскільки Math.tan()
приймає вхідні значення саме в радіанах.
Повернення випадкового цілого числа між вказаними межами
Це можна зробити, взявши комбінацію з Math.random()
і Math.floor()
:
function random(min, max) {
const num = Math.floor(Math.random() * (max - min + 1)) + min;
return num;
}
random(1, 10);
Специфікації
Сумісність із браузерами
desktop | mobile | server | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Math
|
Chrome Full support 1 | Edge Full support 12 | Firefox Full support 1 | Internet Explorer Full support 3 | Opera Full support 3 | Safari Full support 1 | WebView Android Full support 1 | Chrome Android Full support 18 | Firefox for Android Full support 4 | Opera Android Full support 10.1 | Safari on iOS Full support 1 | Samsung Internet Full support 1.0 | Deno Full support 1.0 | Node.js Full support 0.10.0 |
E
|
Chrome Full support 1 | Edge Full support 12 | Firefox Full support 1 | Internet Explorer Full support 3 | Opera Full support 3 | Safari Full support 1 | WebView Android Full support 1 | Chrome Android Full support 18 | Firefox for Android Full support 4 | Opera Android Full support 10.1 | Safari on iOS Full support 1 | Samsung Internet Full support 1.0 | Deno Full support 1.0 | Node.js Full support 0.10.0 |
LN10
|
Chrome Full support 1 | Edge Full support 12 | Firefox Full support 1 | Internet Explorer Full support 3 | Opera Full support 3 | Safari Full support 1 | WebView Android Full support 1 | Chrome Android Full support 18 | Firefox for Android Full support 4 | Opera Android Full support 10.1 | Safari on iOS Full support 1 | Samsung Internet Full support 1.0 | Deno Full support 1.0 | Node.js Full support 0.10.0 |
LN2
|
Chrome Full support 1 | Edge Full support 12 | Firefox Full support 1 | Internet Explorer Full support 3 | Opera Full support 3 | Safari Full support 1 | WebView Android Full support 1 | Chrome Android Full support 18 | Firefox for Android Full support 4 | Opera Android Full support 10.1 | Safari on iOS Full support 1 | Samsung Internet Full support 1.0 | Deno Full support 1.0 | Node.js Full support 0.10.0 |
LOG10E
|
Chrome Full support 1 | Edge Full support 12 | Firefox Full support 1 | Internet Explorer Full support 3 | Opera Full support 3 | Safari Full support 1 | WebView Android Full support 1 | Chrome Android Full support 18 | Firefox for Android Full support 4 | Opera Android Full support 10.1 | Safari on iOS Full support 1 | Samsung Internet Full support 1.0 | Deno Full support 1.0 | Node.js Full support 0.10.0 |
LOG2E
|
Chrome Full support 1 | Edge Full support 12 | Firefox Full support 1 | Internet Explorer Full support 3 | Opera Full support 3 | Safari Full support 1 | WebView Android Full support 1 | Chrome Android Full support 18 | Firefox for Android Full support 4 | Opera Android Full support 10.1 | Safari on iOS Full support 1 | Samsung Internet Full support 1.0 | Deno Full support 1.0 | Node.js Full support 0.10.0 |
PI
|
Chrome Full support 1 | Edge Full support 12 | Firefox Full support 1 | Internet Explorer Full support 3 | Opera Full support 3 | Safari Full support 1 | WebView Android Full support 1 | Chrome Android Full support 18 | Firefox for Android Full support 4 | Opera Android Full support 10.1 | Safari on iOS Full support 1 | Samsung Internet Full support 1.0 | Deno Full support 1.0 | Node.js Full support 0.10.0 |
SQRT1_2
|
Chrome Full support 1 | Edge Full support 12 | Firefox Full support 1 | Internet Explorer Full support 3 | Opera Full support 3 | Safari Full support 1 | WebView Android Full support 1 | Chrome Android Full support 18 | Firefox for Android Full support 4 | Opera Android Full support 10.1 | Safari on iOS Full support 1 | Samsung Internet Full support 1.0 | Deno Full support 1.0 | Node.js Full support 0.10.0 |
SQRT2
|
Chrome Full support 1 | Edge Full support 12 | Firefox Full support 1 | Internet Explorer Full support 3 | Opera Full support 3 | Safari Full support 1 | WebView Android Full support 1 | Chrome Android Full support 18 | Firefox for Android Full support 4 | Opera Android Full support 10.1 | Safari on iOS Full support 1 | Samsung Internet Full support 1.0 | Deno Full support 1.0 | Node.js Full support 0.10.0 |
abs
|
Chrome Full support 1 | Edge Full support 12 | Firefox Full support 1 | Internet Explorer Full support 3 | Opera Full support 3 | Safari Full support 1 | WebView Android Full support 1 | Chrome Android Full support 18 | Firefox for Android Full support 4 | Opera Android Full support 10.1 | Safari on iOS Full support 1 | Samsung Internet Full support 1.0 | Deno Full support 1.0 | Node.js Full support 0.10.0 |
acos
|
Chrome Full support 1 | Edge Full support 12 | Firefox Full support 1 | Internet Explorer Full support 3 | Opera Full support 3 | Safari Full support 1 | WebView Android Full support 1 | Chrome Android Full support 18 | Firefox for Android Full support 4 | Opera Android Full support 10.1 | Safari on iOS Full support 1 | Samsung Internet Full support 1.0 | Deno Full support 1.0 | Node.js Full support 0.10.0 |
acosh
|
Chrome Full support 38 | Edge Full support 12 | Firefox Full support 25 | Internet Explorer No support Ні | Opera Full support 25 | Safari Full support 8 | WebView Android Full support 38 | Chrome Android Full support 38 | Firefox for Android Full support 25 | Opera Android Full support 25 | Safari on iOS Full support 8 | Samsung Internet Full support 3.0 | Deno Full support 1.0 | Node.js Full support 0.12.0 |
asin
|
Chrome Full support 1 | Edge Full support 12 | Firefox Full support 1 | Internet Explorer Full support 3 | Opera Full support 3 | Safari Full support 1 | WebView Android Full support 1 | Chrome Android Full support 18 | Firefox for Android Full support 4 | Opera Android Full support 10.1 | Safari on iOS Full support 1 | Samsung Internet Full support 1.0 | Deno Full support 1.0 | Node.js Full support 0.10.0 |
asinh
|
Chrome Full support 38 | Edge Full support 12 | Firefox Full support 25 | Internet Explorer No support Ні | Opera Full support 25 | Safari Full support 8 | WebView Android Full support 38 | Chrome Android Full support 38 | Firefox for Android Full support 25 | Opera Android Full support 25 | Safari on iOS Full support 8 | Samsung Internet Full support 3.0 | Deno Full support 1.0 | Node.js Full support 0.12.0 |
atan
|
Chrome Full support 1 | Edge Full support 12 | Firefox Full support 1 | Internet Explorer Full support 3 | Opera Full support 3 | Safari Full support 1 | WebView Android Full support 1 | Chrome Android Full support 18 | Firefox for Android Full support 4 | Opera Android Full support 10.1 | Safari on iOS Full support 1 | Samsung Internet Full support 1.0 | Deno Full support 1.0 | Node.js Full support 0.10.0 |
atan2
|
Chrome Full support 1 | Edge Full support 12 | Firefox Full support 1 | Internet Explorer Full support 4 | Opera Full support 3 | Safari Full support 1 | WebView Android Full support 1 | Chrome Android Full support 18 | Firefox for Android Full support 4 | Opera Android Full support 10.1 | Safari on iOS Full support 1 | Samsung Internet Full support 1.0 | Deno Full support 1.0 | Node.js Full support 0.10.0 |
atanh
|
Chrome Full support 38 | Edge Full support 12 | Firefox Full support 25 | Internet Explorer No support Ні | Opera Full support 25 | Safari Full support 8 | WebView Android Full support 38 | Chrome Android Full support 38 | Firefox for Android Full support 25 | Opera Android Full support 25 | Safari on iOS Full support 8 | Samsung Internet Full support 3.0 | Deno Full support 1.0 | Node.js Full support 0.12.0 |
cbrt
|
Chrome Full support 38 | Edge Full support 12 | Firefox Full support 25 | Internet Explorer No support Ні | Opera Full support 25 | Safari Full support 8 | WebView Android Full support 38 | Chrome Android Full support 38 | Firefox for Android Full support 25 | Opera Android Full support 25 | Safari on iOS Full support 8 | Samsung Internet Full support 3.0 | Deno Full support 1.0 | Node.js Full support 0.12.0 |
ceil
|
Chrome Full support 1 | Edge Full support 12 | Firefox Full support 1 | Internet Explorer Full support 3 | Opera Full support 3 | Safari Full support 1 | WebView Android Full support 1 | Chrome Android Full support 18 | Firefox for Android Full support 4 | Opera Android Full support 10.1 | Safari on iOS Full support 1 | Samsung Internet Full support 1.0 | Deno Full support 1.0 | Node.js Full support 0.10.0 |
clz32
|
Chrome Full support 38 | Edge Full support 12 | Firefox Full support 31 | Internet Explorer No support Ні | Opera Full support 25 | Safari Full support 7 | WebView Android Full support 38 | Chrome Android Full support 38 | Firefox for Android Full support 31 | Opera Android Full support 25 | Safari on iOS Full support 7 | Samsung Internet Full support 3.0 | Deno Full support 1.0 | Node.js Full support 0.12.0 |
cos
|
Chrome Full support 1 | Edge Full support 12 | Firefox Full support 1 | Internet Explorer Full support 3 | Opera Full support 3 | Safari Full support 1 | WebView Android Full support 1 | Chrome Android Full support 18 | Firefox for Android Full support 4 | Opera Android Full support 10.1 | Safari on iOS Full support 1 | Samsung Internet Full support 1.0 | Deno Full support 1.0 | Node.js Full support 0.10.0 |
cosh
|
Chrome Full support 38 | Edge Full support 12 | Firefox Full support 25 | Internet Explorer No support Ні | Opera Full support 25 | Safari Full support 8 | WebView Android Full support 38 | Chrome Android Full support 38 | Firefox for Android Full support 25 | Opera Android Full support 25 | Safari on iOS Full support 8 | Samsung Internet Full support 3.0 | Deno Full support 1.0 | Node.js Full support 0.12.0 |
exp
|
Chrome Full support 1 | Edge Full support 12 | Firefox Full support 1 | Internet Explorer Full support 3 | Opera Full support 3 | Safari Full support 1 | WebView Android Full support 1 | Chrome Android Full support 18 | Firefox for Android Full support 4 | Opera Android Full support 10.1 | Safari on iOS Full support 1 | Samsung Internet Full support 1.0 | Deno Full support 1.0 | Node.js Full support 0.10.0 |
expm1
|
Chrome Full support 38 | Edge Full support 12 | Firefox Full support 25 | Internet Explorer No support Ні | Opera Full support 25 | Safari Full support 8 | WebView Android Full support 38 | Chrome Android Full support 38 | Firefox for Android Full support 25 | Opera Android Full support 25 | Safari on iOS Full support 8 | Samsung Internet Full support 3.0 | Deno Full support 1.0 | Node.js Full support 0.12.0 |
floor
|
Chrome Full support 1 | Edge Full support 12 | Firefox Full support 1 | Internet Explorer Full support 3 | Opera Full support 3 | Safari Full support 1 | WebView Android Full support 1 | Chrome Android Full support 18 | Firefox for Android Full support 4 | Opera Android Full support 10.1 | Safari on iOS Full support 1 | Samsung Internet Full support 1.0 | Deno Full support 1.0 | Node.js Full support 0.10.0 |
fround
|
Chrome Full support 38 | Edge Full support 12 | Firefox Full support 26 | Internet Explorer No support Ні | Opera Full support 25 | Safari Full support 8 | WebView Android Full support 38 | Chrome Android Full support 38 | Firefox for Android Full support 26 | Opera Android Full support 25 | Safari on iOS Full support 8 | Samsung Internet Full support 3.0 | Deno Full support 1.0 | Node.js Full support 0.12.0 |
hypot
|
Chrome Full support 38 | Edge Full support 12 | Firefox Full support 27 | Internet Explorer No support Ні | Opera Full support 25 | Safari Full support 8 | WebView Android Full support 38 | Chrome Android Full support 38 | Firefox for Android Full support 27 | Opera Android Full support 25 | Safari on iOS Full support 8 | Samsung Internet Full support 3.0 | Deno Full support 1.0 | Node.js Full support 0.12.0 |
imul
|
Chrome Full support 28 | Edge Full support 12 | Firefox Full support 20 | Internet Explorer No support Ні | Opera Full support 16 | Safari Full support 7 | WebView Android Full support 4.4 | Chrome Android Full support 28 | Firefox for Android Full support 20 | Opera Android Full support 15 | Safari on iOS Full support 7 | Samsung Internet Full support 1.5 | Deno Full support 1.0 | Node.js Full support 0.12.0 |
log
|
Chrome Full support 1 | Edge Full support 12 | Firefox Full support 1 | Internet Explorer Full support 3 | Opera Full support 3 | Safari Full support 1 | WebView Android Full support 1 | Chrome Android Full support 18 | Firefox for Android Full support 4 | Opera Android Full support 10.1 | Safari on iOS Full support 1 | Samsung Internet Full support 1.0 | Deno Full support 1.0 | Node.js Full support 0.10.0 |
log10
|
Chrome Full support 38 | Edge Full support 12 | Firefox Full support 25 | Internet Explorer No support Ні | Opera Full support 25 | Safari Full support 8 | WebView Android Full support 38 | Chrome Android Full support 38 | Firefox for Android Full support 25 | Opera Android Full support 25 | Safari on iOS Full support 8 | Samsung Internet Full support 3.0 | Deno Full support 1.0 | Node.js Full support 0.12.0 |
log1p
|
Chrome Full support 38 | Edge Full support 12 | Firefox Full support 25 | Internet Explorer No support Ні | Opera Full support 25 | Safari Full support 8 | WebView Android Full support 38 | Chrome Android Full support 38 | Firefox for Android Full support 25 | Opera Android Full support 25 | Safari on iOS Full support 8 | Samsung Internet Full support 3.0 | Deno Full support 1.0 | Node.js Full support 0.12.0 |
log2
|
Chrome Full support 38 | Edge Full support 12 | Firefox Full support 25 | Internet Explorer No support Ні | Opera Full support 25 | Safari Full support 8 | WebView Android Full support 38 | Chrome Android Full support 38 | Firefox for Android Full support 25 | Opera Android Full support 25 | Safari on iOS Full support 8 | Samsung Internet Full support 3.0 | Deno Full support 1.0 | Node.js Full support 0.12.0 |
max
|
Chrome Full support 1 | Edge Full support 12 | Firefox Full support 1 | Internet Explorer Full support 3 | Opera Full support 3 | Safari Full support 1 | WebView Android Full support 1 | Chrome Android Full support 18 | Firefox for Android Full support 4 | Opera Android Full support 10.1 | Safari on iOS Full support 1 | Samsung Internet Full support 1.0 | Deno Full support 1.0 | Node.js Full support 0.10.0 |
min
|
Chrome Full support 1 | Edge Full support 12 | Firefox Full support 1 | Internet Explorer Full support 3 | Opera Full support 3 | Safari Full support 1 | WebView Android Full support 1 | Chrome Android Full support 18 | Firefox for Android Full support 4 | Opera Android Full support 10.1 | Safari on iOS Full support 1 | Samsung Internet Full support 1.0 | Deno Full support 1.0 | Node.js Full support 0.10.0 |
pow
|
Chrome Full support 1 | Edge Full support 12 | Firefox Full support 1 | Internet Explorer Full support 3 | Opera Full support 3 | Safari Full support 1 | WebView Android Full support 1 | Chrome Android Full support 18 | Firefox for Android Full support 4 | Opera Android Full support 10.1 | Safari on iOS Full support 1 | Samsung Internet Full support 1.0 | Deno Full support 1.0 | Node.js Full support 0.10.0 |
random
|
Chrome Full support 1 | Edge Full support 12 | Firefox Full support 1 | Internet Explorer Full support 3 | Opera Full support 3 | Safari Full support 1 | WebView Android Full support 1 | Chrome Android Full support 18 | Firefox for Android Full support 4 | Opera Android Full support 10.1 | Safari on iOS Full support 1 | Samsung Internet Full support 1.0 | Deno Full support 1.0 | Node.js Full support 0.10.0 |
round
|
Chrome Full support 1 | Edge Full support 12 | Firefox Full support 1 | Internet Explorer Full support 3 | Opera Full support 3 | Safari Full support 1 | WebView Android Full support 1 | Chrome Android Full support 18 | Firefox for Android Full support 4 | Opera Android Full support 10.1 | Safari on iOS Full support 1 | Samsung Internet Full support 1.0 | Deno Full support 1.0 | Node.js Full support 0.10.0 |
sign
|
Chrome Full support 38 | Edge Full support 12 | Firefox Full support 25 | Internet Explorer No support Ні | Opera Full support 25 | Safari Full support 9 | WebView Android Full support 38 | Chrome Android Full support 38 | Firefox for Android Full support 25 | Opera Android Full support 25 | Safari on iOS Full support 9 | Samsung Internet Full support 3.0 | Deno Full support 1.0 | Node.js Full support 0.12.0 |
sin
|
Chrome Full support 1 | Edge Full support 12 | Firefox Full support 1 | Internet Explorer Full support 3 | Opera Full support 3 | Safari Full support 1 | WebView Android Full support 1 | Chrome Android Full support 18 | Firefox for Android Full support 4 | Opera Android Full support 10.1 | Safari on iOS Full support 1 | Samsung Internet Full support 1.0 | Deno Full support 1.0 | Node.js Full support 0.10.0 |
sinh
|
Chrome Full support 38 | Edge Full support 12 | Firefox Full support 25 | Internet Explorer No support Ні | Opera Full support 25 | Safari Full support 8 | WebView Android Full support 38 | Chrome Android Full support 38 | Firefox for Android Full support 25 | Opera Android Full support 25 | Safari on iOS Full support 8 | Samsung Internet Full support 3.0 | Deno Full support 1.0 | Node.js Full support 0.12.0 |
sqrt
|
Chrome Full support 1 | Edge Full support 12 | Firefox Full support 1 | Internet Explorer Full support 3 | Opera Full support 3 | Safari Full support 1 | WebView Android Full support 1 | Chrome Android Full support 18 | Firefox for Android Full support 4 | Opera Android Full support 10.1 | Safari on iOS Full support 1 | Samsung Internet Full support 1.0 | Deno Full support 1.0 | Node.js Full support 0.10.0 |
tan
|
Chrome Full support 1 | Edge Full support 12 | Firefox Full support 1 | Internet Explorer Full support 3 | Opera Full support 3 | Safari Full support 1 | WebView Android Full support 1 | Chrome Android Full support 18 | Firefox for Android Full support 4 | Opera Android Full support 10.1 | Safari on iOS Full support 1 | Samsung Internet Full support 1.0 | Deno Full support 1.0 | Node.js Full support 0.10.0 |
tanh
|
Chrome Full support 38 | Edge Full support 12 | Firefox Full support 25 | Internet Explorer No support Ні | Opera Full support 25 | Safari Full support 8 | WebView Android Full support 38 | Chrome Android Full support 38 | Firefox for Android Full support 25 | Opera Android Full support 25 | Safari on iOS Full support 8 | Samsung Internet Full support 3.0 | Deno Full support 1.0 | Node.js Full support 0.12.0 |
trunc
|
Chrome Full support 38 | Edge Full support 12 | Firefox Full support 25 | Internet Explorer No support Ні | Opera Full support 25 | Safari Full support 8 | WebView Android Full support 38 | Chrome Android Full support 38 | Firefox for Android Full support 25 | Opera Android Full support 25 | Safari on iOS Full support 8 | Samsung Internet Full support 3.0 | Deno Full support 1.0 | Node.js Full support 0.12.0 |