FreeBASIC - Division: /

Division is a matematical operation, it can be used for integers and real numbers.

/

Description

par1 / par2
Used keywords: /

Input


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

FreeBASIC

Division the possible of use:
x = 64 / 8   ' x=8
y = x / 0.5   ' y=16
z = (x * 2 / y +5)' z=1.1

FreeBASIC

Even one example in what situations we can use the operation division:
i / &Hab
27 / 3
(2.5 / 2 + 1.25) + 2

FreeBASIC

Other pieces of example codes:
y = x / &Ha
50 / i
y = x / &Ha
(x / 5)
x >= y / 5
y = y/ 3.14

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