Returns the product of two numbers that are treated as 32-bit signed integers.
Syntax
Math.imul(x, y);
Parameters
x
Required. The first number.
y
Required. The second number.
Remarks
This function is used for compilers like Emscripten and Mandreel, which don't implement integer multiplication in the same way as JavaScript.
Example
The following code example shows how to multiply numbers using Math.imul.
var result1 = Math.imul(2, 5);
// result1 == 10
var result2 = Math.imul(Math.pow(2, 32) - 1, Math.pow(2, 32) - 2);
// result2 == 2
Requirements
Supported in Microsoft Edge (Edge browser). Also supported in Store apps (Microsoft Edge on Windows 10). See Version Information.
Not supported in the following document modes: Quirks, Internet Explorer 6 standards, Internet Explorer 7 standards, Internet Explorer 8 standards, Internet Explorer 9 standards, Internet Explorer 10 standards, Internet Explorer 11 standards. Not supported in Windows 8.1.

