GATE EE 2014 Set 2 — Question 62
Go beyond PYQs with Success TrackerAI-powered personalised practice and doubt support. Unlimited practice on eligible plans; AI usage limits apply.MCQ+2 / -0.67MediumDigital Logic CircuitsAnalog & Digital Electronics
Analog & Digital Electronics → Digital Logic Circuits
Last updated
Question
In an 8085 microprocessor, the following program is executedAt the end of program, register A contains
Address location – Instruction
2000H XRA A
2001H MVI B,04H
2003H MVI A, 03H
2005H RAR
2006H DCR B
2007H JNZ 2005
200AH HLT
Correct answer
(A) 60H
Solution
Let's trace the program execution step-by-step:
Final value in A is .
1.
2000H XRA A: Register A is XORed with itself. , and the Carry flag () is cleared ().2.
2001H MVI B, 04H: Register B is loaded with . ()3.
2003H MVI A, 03H: Register A is loaded with . ()4.Loop starts at
2005H:- Iteration 1:
RAR(Rotate A Right through Carry). , . AfterRAR, and .DCR Bmakes .JNZ 2005jumps back. - Iteration 2:
RAR. , . AfterRAR, and .DCR Bmakes .JNZ 2005jumps back. - Iteration 3:
RAR. , . AfterRAR, and .DCR Bmakes .JNZ 2005jumps back. - Iteration 4:
RAR. , . AfterRAR, and .DCR Bmakes .JNZ 2005does not jump.
200AH HLT: Program halts.Final value in A is .
Continue learning with Success Tracker
A step still unclear? Work through it with support
Use Success Tracker to ask about the reasoning, then try another GATE EE question to check your understanding.
AI-powered practice· Unlimited practice on eligible plans
- PYQs with solutions
- Attempt available previous-year questions, then compare your reasoning with the worked solution. Coverage varies by stream.
- Practice that adapts
- Choose a topic, work on weaker areas and bookmark questions to revisit. Your attempts feed your progress tracking.
- AI doubt support
- Ask follow-up questions about a step or concept while practising, instead of stopping at the final answer.
Unlimited practice is available on eligible plans. Free practice and AI usage have limits; check the current plan allowances before choosing.
This page stays readable without an account. AI responses can be wrong; check them against the solution and source material.
More questions on Digital Logic Circuits
2026 Set 1 Q33In the linear regulator circuit shown, the base to emitter voltage of the BJT is…2026 Set 1 Q37In the circuit shown, the open loop gain of the operational amplifier is . What is the…2026 Set 1 Q45The digital circuit shown has 3 inputs (, , and ). The simplified logical expression for…2026 Set 1 Q46The MOSFET switches shown in the circuit are ideal. [figure] Which of the following is the correct…2026 Set 1 Q61Consider the circuit shown. Assume that the diode () is ideal. Given …