org 100
input
store x
input
store y
JnS prod
Load sum
store e
input
store x
input
store y
jns prod
load sum
store f
load e
add f
output
halt
sum, dec 0
one, dec 1
ctr, dec 0
x, dec 0
y, dec 0
e, dec 0
f, dec 0
prod, hex 0
load y
store ctr
clear
store sum
Loop, Load sum
Add x
Store sum
Load ctr
Subt one
Store ctr
Skipcond 400
Jump Loop
load sum
JumpI prod