OIN: MVI B,0 ; ANSWER :=0; OINLOOP:CALL GET ; A := INPUT [character]; CPI '0' ; is A LT '0'? RC ; if so then return; CPI '8' ; is A LT '8'? RNC ; If not then return; ANI 7 ; A := A & b'00000111' [mask loworder]; MOV C,A ; C := A; MOV A,B ; A := ANSWER; RLC ; rotate A left three RC ; bit positions RLC ; and check for RC ; overflow into RLC ; CARRY after RC ; each operation; ORA C ; A := A OR ANSWER; MOV B,A ; ANSWER := A; JMP OINLOOP ; reiterate for next digit;