shell兩個數字相乘
Problem statement:
問題陳述:
To perform multiplication operation between 2 16bit numbers with carry using 8086 Microprocessor.
使用8086微處理器在2個16位數字之間進行帶進位的乘法運算。
Algorithm:
算法:
Load the first data into register AX from memory.
從存儲器將第一個數據加載到寄存器AX中。
Load the second data into register BX from memory.
將第二個數據從內存加載到寄存器BX中。
Multiply content of register BX with the content of register AX.
將寄存器BX的內容與寄存器AX的內容相乘。
Now load the result value from AX to memory.
現在將結果值從AX加載到內存。
Move data from DX to AX.
將數據從DX移動到AX。
Now Load the data from AX to memory.
現在,將數據從AX加載到內存。
Program:
程序:
MOV AX, 2050
MOV BX, 2052
MUL BX
MOV 2054, AX
MOV AX, DX
MOV 2056, AX
HLT
Observation:
觀察:
INPUT:
2050:04
2051:03
2052:07
2053:08
OUTPUT:
2054:00
2055:1C
2056:35
Hence we successfully multiplied two 16 bits numbers using carry.
因此,我們成功地使用進位將兩個16位數字相乘 。
翻譯自: https://www.includehelp.com/embedded-system/multiplication-of-two-16-bits-numbers-without-carry-using-8086-microprocessor.aspx
shell兩個數字相乘