Quick Index
Meet the Niesens
Our Wedding
School, Employment, & Resume
Hobbies & Interests
Weekly Picture Archive
Recipes
Aldi
Product Reviews
Links
Mail to
Claus
Melissa
|
Low-Level Program Segment
-----------------------------------------------------------
L R1, ZERO initialize i to 0 page 0
L R2, n
L1: CMP R1, R2 branch if i exceeds n
BG L4
-----------------------------------------------------------
L R3, ZERO initialize SUM[i] to 0 page 1
ST R3, SUM[R1]
L R4, ZERO initialize j to 0
L R5, m
-----------------------------------------------------------
L2: CMP R4, R5 branch if j exceeds m page 2
BG L3
LR R6, n n
SR R6, R1 n-i
-----------------------------------------------------------
AR R6, R4 (n-i)+j page 3
ST R6, X
A R6, SUM[R1]
ST R6, SUM[R1]
-----------------------------------------------------------
L R7, n page 4
A R7, ONE n+1
MR R7, R1 i*(n+1)
AR R7, R4 i*(n+1)+j
-----------------------------------------------------------
ST R6, A[R7] store X in A[i,j] page 5
A R4, ONE increment j
B L2
L3: A R1, ONE increment i
-----------------------------------------------------------
B L1 page 6
L4: L R3, ONE initialize PROD to 1
L R1, ZERO initialize i to 0
L R2, n
-----------------------------------------------------------
L5: CMP R1, R2 branch if i exceeds n page 7
BG L6
M R3, PROD[R1]
A R1, ONE increment i
-----------------------------------------------------------
B L5 page 8
L6:
...
-----------------------------------------------------------
ZERO page 9
ONE
n
m
-----------------------------------------------------------
A page 10
...
-----------------------------------------------------------
SUM page 11
...
-----------------------------------------------------------
PROD page 12
...
-----------------------------------------------------------
X page 13
...
-----------------------------------------------------------
|