test |
---|
foo |
This operator performs integer division, with the result truncated to an integer value.
If the second argument is zero then a Division_by_zero
exception is thrown. Refer to the Exception section for handling exceptions.
<CodeTab labels={["ReScript", "JS Output"]}>
let result = 3 / 2
var result = 1;
For dividing floats see the /.
operator.