/ (Division)
Syntax
argument1 / argument2
Description
The division operator is used to divide (or to find the ratio of) two numbers and return an integer result. Division is the inverse of multiplication, *. The arguments argument1 and argument2 can be any valid numerical expression. If either argument is an uninitialized variable, that argument will be evaluated as zero. If argument2 is zero, a division by zero will be raised.
Example
PRINT n / 5
n = 600000 / 23
PRINT n
SLEEP
The output would look like:
0
26086
Differences from other BASICs
- None with PBASIC
- Visual BASIC returns a floating point result