Write an Assembly language program as per following instructions and tell what w
ID: 3625735 • Letter: W
Question
Write an Assembly language program as per following instructions and tell what will be the value of CX and BL registers at the End of your program?Let say your Roll number is MC789207290. So you need to initialize CX with 0, and BX with the least two significant digits of your roll no. i.e. (90 in this case). After this you need to execute the following loop instructions.
Label1: inc bl
inc cx
cmp bl, 0
jnz Label1
Report your values in the BL and CX registers after the execution of the above loop with brief explanation.
-------------------------------------------------------------------------------------------------------
Write an Assembly language program as per following instructions and tell what will be the value of BX and CX registers at the End of your program?
Again, Let say your Roll number is MC789207290. So you need to initialize BX with 90 (least two significant digits of your roll no.), and CX with 72 (the next two least significant digits of your roll no.). After this you need to execute the following three XOR instructions.
xor cx, bx
xor bx, cx
xor cx, bx
Report your values in the BX and CX registers after the execution of the above three XOR instructions with brief explanation.
-------------------------------------------------------------------------------------------------------
For both Answer verfication use AFD debugger.
Explanation / Answer
[org 0x0100]
mov cx, 0
mov bl,49
Label1: inc bl
inc cx
cmp bl, 0
jnz Label1
mov ax, 0x4c00
int 0x21
xor cx, bx
xor bx, cx
xor cx, bx
[org 0x0100]
mov cx,50
mov bx,32
xor cx,bx
xor bx,cx
xor cx,bx
mov ax,0x4c00
int 0x21
Related Questions
Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.