310 views

1 Answer

1 votes
1 votes

357) Answer C.1

LXI H 0010H.                    //load register pair HL with 0010H

Contents of H - 0000 0000 , L - 0001 0000

DCX H.                             //decrease contents of register pair HL by 1

Contents of H - 0000 0000,  L - 0000 1111

MOV A L.            // move contents of register L to accumulator

Contents of Accumulator - 0000 1111, H - 0000 0000, L - 0000 1111

ORA H.               // perform OR operation between Accumulator and register H

Contents ofaccumulator - 0000 1111, H - 0000 0000, L - 0000 1111

XRA A.         // exclusive OR operation between accumulator and register A (accumulator)

Contents of Accumulator - 0000 0000, H - 0000 0000, L - 0000 1111

As the contents of accumulator becomes all zeros, zero flag will be set.

JNZ Loop.              // jump to label loop if zero flag is not set.

Here zero flag has set. So it will not loop further. Stop here. So only 1 time LOOP will be executed.

Related questions

0 votes
0 votes
0 answers
1
Anuj1995 asked Aug 22, 2018
402 views
How to solve this type of questions?
2 votes
2 votes
2 answers
2
Meenakshi Sharma asked Nov 19, 2016
2,119 views
0 votes
0 votes
0 answers
3
rahuldb asked Nov 17, 2016
2,097 views
Write the assembly language code segment to evaluate the following arithmetic expression:X=((A+B)*C)/(D-E*F+G*H)Usingi)Stack based organizationii)RISC organization
0 votes
0 votes
0 answers
4
Sanjay Sharma asked Jun 29, 2016
225 views