RosettaCodeData/Task/Arithmetic-Integer/PL-I/arithmetic-integer.pli
2023-07-01 13:44:08 -04:00

7 lines
272 B
Text

get list (a, b);
put skip list (a+b);
put skip list (a-b);
put skip list (a*b);
put skip list (trunc(a/b)); /* truncates towards zero. */
put skip list (mod(a, b)); /* Remainder is always positive. */
put skip list (rem(a, b)); /* Sign can be negative. */