-
An Intel 8085 processor is executing the program given below.
MVI A, 10H
MVI B, 10H
BACK: NOP
ADD B
RLC
JNC
BACK HLT
The number of times that the operation NOP will be executed is equal to—
-
- 1
- 2
- 3
- 4
Correct Option: C
MVI A, 10 H | 10 H ← Accumulator |
MVI A, 10 H | 10 H ← Register B |
MVI B, 10 H | Delay |
NOP (Ist execution) | 2050 |
ADD B | 20 H ← Accumulator |
RLC | 40 H ← Accumulator; CY = 0 |
NOP (2nd execution) | Delay |
ADD B | 40H + 10 H = 50 H ← Accumulator |
RLC | AOH ← Accumulator; CY = 0 |
NOP (3rd execution) | Delay |
ADD B | BOH ← Accumulator |
RLC | 31 H ← Accumulator; CY = 1 |
HLT |
It means operation NOP will be executed 3 times. Hence alternative (C) is the correct choice.