C++ - integer division: /

integer division is a mathematical operation that can be used only for whole numbers. the result of division we get without rounding simply with leave of fraction.

/

Description

par1 / par2
Used keywords: /

Input


Output

compatible programing languages:
Visual C++ .NET

Examples

C++

integer division the possible of use:
x = 250 / 8;       // x=7
y = x / 3;         // y=2
z = (x * 2 / y +5);// z=9

C++

even one example in what situations we can use the operation integer division:
i / 0x0a
27 / 3
(25 / 2 + 1) + 2

C++

Other pieces of example codes:
 y = 10250 / 8
70 / 8
(15123 / 70)
 y = 1025 / 8
(1512345 / 70)

you can find it in the following collections: arithmetic operators
Languages: en hu cz sk