; ; multiply two numbers using the ; mullib library ; ; lcw r1 stack ; set up stack loa r3 r0 ; get first parameter loa r2 r0 ; get second parameter psh r2 ; put second parameter on the stack lcw r2 mlmul ; call multiply cal r2 r2 ; pop r0 ; just for consistency, clean up the stack sto r3 r0 ; write result, hlt ; and halt ; ; include the multiplication library ; the file mullib.a52 should be in the same ; directory as this file ; inc mullib ; ; stack area: 50 words ; dat 100 stack