(汇编新手)这段代码该怎么修改??
;Y = (A - B * C) / A;商:y 余:x
DATA SEGMENT
A DB 3
B DB 2
C DB 1
X DB ?
Y DB ?
DATA ENDS
CODE SEGMENT
ASSUME DS:DATA, CS:CODE
MAIN PROC FAR
START:
MOV AL, B
IMUL C ; AL = B * C
MOV BL, A
MOV CL, BL
SUB BL, AL ; BL = A - B * C
IDIV CL
MOV Y, AL
MOV X, AH
RET
MAIN ENDP
CODE ENDS
END START
页:
[1]