C <-> Pascal | Division
C Used keywords: /
/
Description
par1 / par2
Input
- par1 - At least one real number
- par2 - At least one real number
Output
- Result - Real numbers Result of the division is always a real number.
Note: If we want a integer as a result, so let's use the integer division operation or by using some rounding function we can convert the result to an integer.
Examples
C
Division the possible of use:x = (float)64 / 8; // x=8
y = x / 0.5; // y=16
z = ((float)(x * 2) / y +5);// z=1.1
C
Even one example in what situations we can use the operation division:(float)i / 0xab
(float)27 / 3
(2.5 / 2 + 1.25) + 2
.
Pascal Used keywords: /
/
Description
par1 / par2
Input
- par1 - Any number
- par2 - Any number
Output
- Result - Real numbers Result of the division is always a real number.
Note: If we want a integer as a result, so let's use the integer division operation or by using some rounding function we can convert the result to an integer.
Examples
Pascal
Division the possible of use:x := 64 / 8; { x=8}
y := x / 0.5; { y=16}
z := (x * 2 / y +5);{ z=1.1}
Pascal
Even one example in what situations we can use the operation division:i / $ab
27 / 3
(2.5 / 2 + 1.25) + 2
C Used keywords: /
/
Description
par1 / par2
Input
- par1 - Any integer
- par2 - Any integer
Output
- Result - Real numbers Result of the division is always a real number.
Note: If we want a integer as a result, so let's use the integer division operation or by using some rounding function we can convert the result to an integer.
Examples
C
Division the possible of use:x = (float)64 / 8; // x=8
y = x / 0.5; // y=16
z = ((float)(x * 2) / y +5);// z=1.1
C
Even one example in what situations we can use the operation division:(float)i / 0xab
(float)27 / 3
(2.5 / 2 + 1.25) + 2
.
Pascal Used keywords: /
/
Description
par1 / par2
Input
- par1 - Any number
- par2 - Any number
Output
- Result - Real numbers Result of the division is always a real number.
Note: If we want a integer as a result, so let's use the integer division operation or by using some rounding function we can convert the result to an integer.
Examples
Pascal
Division the possible of use:x := 64 / 8; { x=8}
y := x / 0.5; { y=16}
z := (x * 2 / y +5);{ z=1.1}
Pascal
Even one example in what situations we can use the operation division:i / $ab
27 / 3
(2.5 / 2 + 1.25) + 2
You can find it in the following collections: arithmetic operators
Division in another programming language:
Differences to: