Aspire's Library

A Place for Latest Exam wise Questions, Videos, Previous Year Papers,
Study Stuff for MCA Examinations - NIMCET

Previous Year Question (PYQs)



The following program is stored in memory unit of the basic computer. What is the content of the accumulator after the execution of program? All location numbers listed below are in hexadecimal.
LocationInstruction
210CLA
211ADD 217
212INC
213STA 217
214LDA 218
215CMA
216AND 217
2171234H
2189CE2H





Solution

Initially,

$AC=0000H$

After $CLA$:

$AC=0000H$

After $ADD\ 217$:

$AC=0000H+1234H=1234H$

After $INC$:

$AC=1235H$

After $STA\ 217$:

$M[217]=1235H$

After $LDA\ 218$:

$AC=9CE2H$

After $CMA$:

$AC=\overline{9CE2H}=631DH$

Now execute $AND\ 217$:

$AC=631DH\ AND\ 1235H$

$631DH=0110\ 0011\ 0001\ 1101$

$1235H=0001\ 0010\ 0011\ 0101$

So,

$AC=0000\ 0010\ 0001\ 0101=0215H$


Online Test Series,
Information About Examination,
Syllabus, Notification
and More.

Click Here to
View More


Online Test Series,
Information About Examination,
Syllabus, Notification
and More.

Click Here to
View More

Ask Your Question or Put Your Review.

loading...