RosettaCodeData/Task/Arithmetic-Integer/Harbour/arithmetic-integer.harbour
2023-07-01 13:44:08 -04:00

11 lines
317 B
Text

procedure Test( a, b )
? "a+b", a + b
? "a-b", a - b
? "a*b", a * b
// The quotient isn't integer, so we use the Int() function, which truncates it downward.
? "a/b", Int( a / b )
// Remainder:
? "a%b", a % b
// Exponentiation is also a base arithmetic operation
? "a**b", a ** b
return