IN H
IN G
MOV H 1
IN D
IN A
IN B
CMP D H
JZ 22
;UP
IN E
MOV F A

LOAD H F
ADD H E
STORE F H
ADD F H
CMP B F
JZ 13
;QRY
MOV F A
MOV H 0

LOAD E F
ADD H E
ADD F H
CMP B F
JZ 23

OUT H
CMP G C
JZ 3
RETURN
