Integer Operator \
Integer Division Operator (\)
The back slash operator performs integer division
This is a great way of dividing and rounding down in one simple operation
The datatype returned is a numeric type appropriate for the datatypes used
Before performing the division any floating-point values are converted to Long
10 \ 3 = 3
Division (\) with Integer Result
The back slash (\) peforms integer division.
12 / 5 = 2
The answer is returned as an Integer.
© 2023 Better Solutions Limited. All Rights Reserved. © 2023 Better Solutions Limited TopPrevNext