REBOL for COBOL programmers

Go to table of contents Go to feedback page

MULTIPLY

Date written: June 27, 2013
Date revised:
Date reviewed:

This page explains some REBOL equivalents of MULTIPLY.


COBOL MULTIPLY

MULTIPLY has a syntax just like you might say it, including but not limited to:

MULTIPLY { identifier-1 } BY identifier-2 [ROUNDED].
         { literal-1    }
MULTIPLY { identifier-1 } BY { identifier-2 } GIVING identifier-3 [ROUNDED].
         { literal-1    }    { literal-2    }
There are other options for remainders and size errors, as you probably know.

The REBOL equivalent

REBOL has a "multiply" function. It also has the "*" function which is the same.

identifier-2: multiply identifier-1 identifier-2
identifier-3: multiply identifier-1 identifier-2