0
我必須編寫一個使用IAS指令集的程序,該指令集將循環兩個數組並將其中的每個元素添加到另一個數組中,並將結果存儲在第三個數組中。例如,我必須取A(1)+ B(1)並將其存儲在C(1)中,然後取A(2)+ B(2)並存儲在C(2)中,依此類推直到我得到A(20)+ B(20)存儲在C(20)中。但我不知道如何創建IAS計數器控制的循環......反正...這裏是我做了什麼..但它不工作:)如何使用IAS指令集將兩個數組的數組相加在一起?
00000001 LOAD M(A[1]) Transfer M(A[1]) to the accumulator
00000101 ADD M(B[1]) Add M(B[1]) to AC and store result in AC
00100001 STOR M(C[1]) Transfer contents of accumulator to memory location C[1]
感謝您的幫助: )